.projects-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1200px;
    width: 100%;
}

.project-card {
    background-color: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.4s ease;
    position: relative;
    height: 360px;
    cursor: pointer;
}

.project-card:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
    z-index: 10;
}

.project-card.expanded {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(1);
    width: 80%;
    max-width: 800px;
    height: auto;
    max-height: 90vh;
    z-index: 100;
    cursor: default;
    overflow-y: auto;
}

.project-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}

.project-content {
    padding: 20px;
}

.project-title {
    font-size: 18px;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 8px;
}

.project-category {
    font-size: 14px;
    color: #6b7280;
    margin-bottom: 12px;
}

.project-description {
    font-size: 14px;
    color: #4a5568;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: all 0.3s ease;
}

.project-card.expanded .project-description {
    -webkit-line-clamp: initial;
}

.project-details {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.project-card.expanded .project-details {
    max-height: 1000px;
    margin-top: 16px;
}

.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.tech-item {
    background-color: #e2e8f0;
    color: #4a5568;
    padding: 4px 10px;
    border-radius: 16px;
    font-size: 12px;
}

.project-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}

.project-link {
    text-decoration: none;
    color: #3182ce;
    font-weight: 500;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.close-button {
    display: none;
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: rgba(255, 255, 255, 0.7);
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    font-size: 18px;
    cursor: pointer;
    color: #4a5568;
}

.project-card.expanded .close-button {
    display: block;
}

.overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 90;
}

.overlay.active {
    display: block;
}