/* Projects Section */
.projects-section {
    background-color: rgba(30, 30, 30, 0.7);
    border-radius: 30px;
    padding: 50px;
    margin: 30px auto;
    width: 95%;
    box-sizing: border-box;
}

/* Projects Header */
.projects-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-bottom: 40px;
    padding: 15px 20px;
    background-color: rgba(25, 25, 25, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.projects-header:hover {
    background-color: rgba(35, 35, 35, 0.9);
    border-color: rgba(142, 255, 84, 0.3);
}

.projects-header .section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
    margin-bottom: 20px;
    flex-wrap: nowrap;
}

.projects-header .section-title h2 {
    font-size: 32px;
    font-weight: 600;
    color: #fff; /* var(--foreground) */
    white-space: nowrap;
}

.projects-header .section-title .title-tag {
    background: #8eff54; /* var(--primary) */
    color: #1a1a1a; /* var(--bg-darker) */
    font-size: 16px;
    font-weight: 600;
    padding: 5px 14px;
    border-radius: 15px;
    margin-left: 0;
    margin-right: 0;
    letter-spacing: 1px;
    display: inline-block;
}

.projects-header p {
    font-size: 18px;
    color: #cccccc;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}

.projects-header p::after {
    content: '';
    display: block;
    width: 50px;
    height: 3px;
    background-color: #8eff54; /* var(--primary) */
    margin: 25px auto 0;
    border-radius: 2px;
}

/* Projects Content (unchanged from original) */
.projects-content {
    max-height: 0;
    overflow: hidden;
    padding: 0 20px;
    opacity: 1;
    transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.projects-content.active {
    padding: 20px;
}

.projects-nav {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 40px;
}

.project-filter {
    color: #ffffff;
    font-weight: 500;
    font-size: 16px;
    cursor: pointer;
    transition: color 0.3s ease;
    white-space: nowrap;
}

.project-filter.active,
.project-filter:hover {
    color: #8eff54;
    font-weight: 600;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 50px;
}

.project-card {
    background-color: rgba(25, 25, 25, 0.7);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    will-change: transform;
}

.project-card.hidden {
    display: none;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    border-color: rgba(142, 255, 84, 0.3);
}

.project-image {
    position: relative;
    overflow: hidden;
    height: 200px;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.project-category,
.project-type {
    position: absolute;
    top: 15px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    z-index: 1;
}

.project-category {
    left: 15px;
    background-color: #8eff54;
    color: #000;
}

.project-type {
    right: 15px;
    background-color: rgba(142, 255, 84, 0.9);
    color: #000;
}

.project-type.team {
    background-color: rgba(255, 255, 255, 0.9);
    color: #000;
}

.project-content {
    padding: 25px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.project-title {
    font-size: 20px;
    margin-bottom: 0;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.project-card:hover .project-title {
    color: #8eff54;
}

.project-description {
    color: #ddd;
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.project-stacks {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.stack-tag {
    background-color: rgba(142, 255, 84, 0.1);
    color: #8eff54;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 13px;
    font-weight: 500;
}

.project-actions {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.action-btn {
    font-size: 14px;
    font-weight: 500;
    padding: 6px 12px;
    border-radius: 15px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
}

.action-btn.live-demo {
    color: #8eff54;
    border: 1px solid #8eff54;
    background: transparent;
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

.action-btn.live-demo:hover {
    background: rgba(142, 255, 84, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(142, 255, 84, 0.2);
}

.action-btn.github-repo {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: transparent;
    transition: color 0.3s ease, border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

.action-btn.github-repo:hover {
    color: #8eff54;
    border-color: #8eff54;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(142, 255, 84, 0.2);
}

.projects-cta {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

/* Responsive adjustments for tablets */
@media (max-width: 1100px) {
    .projects-header .section-title h2 {
        font-size: 28px;
    }
    .projects-header p {
        font-size: 16px;
    }
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
        padding: 0 4vw;
    }
    .projects-nav {
        gap: 18px;
    }
}

/* Full Mobile Compatibility */
@media (max-width: 768px) {
    .projects-section {
        padding: 15px;
        margin: 10px auto;
        width: 100%;
    }
    .projects-header {
        margin-bottom: 30px;
        padding: 10px 15px;
    }
    .projects-header .section-title h2 {
        font-size: 24px;
    }
    .projects-header p {
        font-size: 14px;
    }
    .projects-header p::after {
        margin: 20px auto 0;
    }
    .projects-content {
        padding: 0 10px;
    }
    .projects-content.active {
        padding: 10px;
    }
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    .project-card {
        width: 100%;
    }
    .project-image {
        height: 150px;
    }
    .project-filter {
        font-size: 14px;
    }
    .projects-nav {
        gap: 15px;
        flex-wrap: wrap;
    }
    .action-btn {
        padding: 5px 10px;
        font-size: 13px;
        flex: 1;
        min-width: 100px;
    }
}

@media (max-width: 480px) {
    .projects-header .section-title h2 {
        font-size: 22px;
    }
    .projects-header .section-title .title-tag {
        font-size: 14px;
        padding: 4px 12px;
    }
    .projects-header p {
        font-size: 13px;
    }
}