/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
    min-height: 100vh;
    color: #ffffff;
    overflow-x: hidden;
}

header {
    text-align: center;
    padding: 40px 20px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 40px;
}

header h1 {
    font-size: 3rem;
    margin-bottom: 10px;
    background: linear-gradient(45deg, #ffffff, #e0e7ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

header p {
    font-size: 1.2rem;
    opacity: 0.8;
    color: #e0e7ff;
}

/* Projects grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    padding: 20px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Glassmorphism project cards */
.project-card {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    color: #ffffff;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.02));
    border-radius: 20px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.project-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
}

.project-card img {
    width: 100%;
    max-width: 280px;
    border-radius: 15px;
    margin-bottom: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

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

.project-card h2 {
    font-size: 1.6rem;
    margin-bottom: 15px;
    position: relative;
    z-index: 1;
    background: linear-gradient(45deg, #ffffff, #a5b4fc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.project-card p {
    font-size: 1rem;
    margin-bottom: 25px;
    opacity: 0.85;
    position: relative;
    z-index: 1;
    line-height: 1.5;
}

.project-card a {
    display: inline-block;
    padding: 12px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
    font-weight: 500;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.project-card a:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.5);
}

/* Star call-to-action styling */
.project-card p:last-child {
    font-size: 0.9rem;
    color: #ffd700;
    background: rgba(255, 215, 0, 0.1);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 20px;
    padding: 8px 16px;
    margin: 15px auto 0;
    max-width: 200px;
    text-align: center;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
    font-weight: 500;
}

.project-card p:last-child:hover {
    background: rgba(255, 215, 0, 0.2);
    border-color: rgba(255, 215, 0, 0.5);
    transform: scale(1.05);
}

/* Footer */
.footer {
    text-align: center;
    padding: 30px 20px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 40px;
}

.footer a {
    color: #e0e7ff;
    text-decoration: none;
    margin: 0 15px;
    font-size: 1.2em;
    transition: all 0.3s ease;
    position: relative;
}

.footer a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    transition: width 0.3s ease;
}

.footer a:hover::after {
    width: 100%;
}

.footer a:hover {
    color: #ffffff;
    transform: translateY(-2px);
}

/* Responsive design */
@media (max-width: 768px) {
    header h1 {
        font-size: 2.2rem;
    }

    .projects-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 15px;
    }

    .project-card {
        padding: 20px;
    }

    .project-card h2 {
        font-size: 1.4rem;
    }
}

@media (max-width: 480px) {
    header {
        padding: 30px 15px;
    }

    header h1 {
        font-size: 1.8rem;
    }

    .projects-grid {
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 10px;
    }

    .project-card {
        padding: 15px;
    }

    .project-card h2 {
        font-size: 1.3rem;
    }

    .project-card p {
        font-size: 0.9rem;
    }

    .project-card a {
        display: block;
        width: 100%;
        padding: 12px 20px;
        margin-bottom: 10px;
        font-size: 0.9rem;
        text-align: center;
    }

    .project-card a:last-child {
        margin-bottom: 0;
    }

    .project-card img {
        max-width: 250px;
    }

    .project-card p:last-child {
        font-size: 0.8rem;
        padding: 6px 12px;
        margin-top: 10px;
        max-width: 180px;
    }
}

@media (max-width: 768px) and (min-width: 481px) {
    header h1 {
        font-size: 2.2rem;
    }

    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 20px;
        padding: 15px;
    }

    .project-card {
        padding: 20px;
    }

    .project-card h2 {
        font-size: 1.4rem;
    }

    .project-card img {
        max-width: 260px;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 25px;
    }

    .project-card {
        padding: 25px;
    }

    .project-card img {
        max-width: 270px;
    }
}

@media (min-width: 1025px) and (max-width: 1440px) {
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
        gap: 30px;
    }
}

@media (min-width: 1441px) {
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
        gap: 35px;
        max-width: 1600px;
    }

    .project-card {
        padding: 35px;
    }

    .project-card h2 {
        font-size: 1.8rem;
    }

    .project-card p {
        font-size: 1.1rem;
    }

    .project-card img {
        max-width: 320px;
    }
}