.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    overflow-y: auto;
}

.modal-content {
    background: linear-gradient(145deg, #1a1a1a, #2a2a2a);
    margin: 5% auto;
    padding: 20px;
    width: 90%;
    max-width: 1000px;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    position: relative;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-header h2 {
    color: #fff;
    margin: 0;
}

.close {
    color: #fff;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

.close:hover {
    color: #ddd;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px 0;
}

.project-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 20px;
    transition: transform 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.project-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.08);
}

.project-card h3 {
    color: #fff;
    margin: 0 0 10px 0;
    font-size: 1.2em;
}

.project-description {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9em;
    margin-bottom: 15px;
}

.project-links {
    display: flex;
    gap: 15px;
}

.project-links a {
    color: #fff;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 5px;
    font-size: 0.9em;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.project-links .demo-link {
    background: linear-gradient(135deg, #667eea, #764ba2);
}

.project-links .github-link {
    background: #333;
}

.project-links a:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

@media (max-width: 480px) {
    .modal-content {
        margin: 2% auto;
        width: 95%;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }
}