/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* BODY BACKGROUND */
body {
    font-family: Arial, sans-serif;
    color: white;
    text-align: center;

    /* dark to light gradient */
    background: linear-gradient(to bottom, #000000, #444444, #dddddd);
    min-height: 100vh;
}

/* NAVBAR */
nav {
    padding: 15px 0;
}

nav ul {
    list-style: none;
    display: flex;
    justify-content: center;
    gap: 40px;
}

nav a {
    text-decoration: none;
    color: white;
    font-size: 18px;
}

nav a:hover {
    text-decoration: underline;
}

/* LINE */
hr {
    width: 80%;
    margin: 10px auto;
    border: 1px solid #aaa;
}

/* HEADER */
header {
    margin-top: 20px;
}

header h1 {
    font-size: 32px;
    margin-bottom: 10px;
}

header p {
    font-size: 14px;
    color: #ccc;
}

/* PROJECTS */
.projects {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 50px;

    flex-wrap: wrap; /* THIS is what makes it responsive */
    padding: 0 20px;

}

/* CARD */
.card {
    background: #eee;
    padding: 10px;
    border-radius: 4px;

    flex: 1 1 300px; /* responsive sizing */
    max-width: 320px;
}

.card img {
    width: 100%;
    height: auto; /* prevents distortion */
}

/* BUTTON */
.card button {
    margin-top: 10px;
    padding: 8px 12px;
    background: black;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.card button:hover {
    background: #333;
}

@media (max-width: 768px) {

    nav ul {
        flex-direction: column;
        gap: 10px;
    }

    header h1 {
        font-size: 24px;
    }

    header p {
        font-size: 13px;
        padding: 0 10px;
    }

    .projects {
        flex-direction: column;
        align-items: center;
    }

    .card {
        width: 90%;
        max-width: 400px;
    }
}

.btn {
    display: inline-block;
    margin-top: 10px;
    padding: 10px 15px;
    background: black;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 14px;
}

.btn:hover {
    background: #333;
}