body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    line-height: 1.6;
    color: #333;
    background-color: #f4f4f4;
}

header {
    background: #2c3e50;
    color: #fff;
    padding: 1rem 0;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

nav ul li {
    margin: 0 15px;
}

nav ul li a {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    padding: 5px 10px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

nav ul li a:hover,
nav ul li a:focus {
    background-color: #34495e;
    border-radius: 5px;
    color: #ecf0f1;
    outline: 2px solid #5dade2;
    outline-offset: 2px;
}

section {
    padding: 40px 20px;
    margin: 20px auto;
    max-width: 1000px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
}

h1, h2 {
    color: #2c3e50;
    text-align: center;
    margin-bottom: 20px;
}

h1 {
    font-size: 2.8rem;
}

h2 {
    font-size: 2.2rem;
    border-bottom: 2px solid #ecf0f1;
    padding-bottom: 10px;
    margin-bottom: 30px;
}

p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1rem;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
    border-radius: 5px;
}

/* New style for the profile photo */
.profile-photo {
    width: 180px; /* Adjust size as needed */
    height: 180px; /* Adjust size as needed */
    border-radius: 50%; /* Makes the image circular */
    object-fit: cover; /* Ensures the image covers the area without distortion */
    border: 5px solid #2c3e50; /* Add a border for emphasis */
    margin-bottom: 30px; /* Space below the image */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2); /* Subtle shadow */
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    padding: 20px 0;
    justify-content: center;
}

.project-item {
    border: 1px solid #ddd;
    padding: 15px;
    box-sizing: border-box;
    text-align: center;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.project-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
}

.contact-form {
    max-width: 600px;
    margin: 30px auto;
    padding: 25px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background-color: #f9f9f9;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #555;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1rem;
    box-sizing: border-box;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group textarea:focus {
    border-color: #2c3e50;
    box-shadow: 0 0 8px rgba(44, 62, 80, 0.2);
    outline: none;
}

.submit-button {
    display: block;
    width: 100%;
    padding: 15px 25px;
    background-color: #2c3e50;
    color: #fff;
    border: none;
    border-radius: 5px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.submit-button:hover,
.submit-button:focus {
    background-color: #34495e;
    transform: translateY(-2px);
    outline: 2px solid #5dade2;
    outline-offset: 3px;
}

.social-links {
    text-align: center;
    margin-top: 40px;
    margin-bottom: 20px;
}

.social-links a {
    color: #2c3e50;
    font-size: 2.5rem;
    margin: 0 15px;
    transition: color 0.3s ease, transform 0.2s ease;
    display: inline-block;
}

.social-links a:hover,
.social-links a:focus {
    color: #3498db;
    transform: translateY(-3px);
    outline: none;
}

footer {
    text-align: center;
    padding: 20px;
    background: #2c3e50;
    color: #fff;
    margin-top: 30px;
}

footer p {
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.footer-social-icons {
    margin-top: 15px;
}

.footer-social-icons a {
    color: #ecf0f1;
    font-size: 1.8rem;
    margin: 0 10px;
    text-decoration: none;
    transition: color 0.3s ease, transform 0.2s ease;
    display: inline-block;
}

.footer-social-icons a:hover,
.footer-social-icons a:focus {
    color: #fff;
    transform: translateY(-2px);
    outline: 2px solid #5dade2;
    outline-offset: 2px;
}

@media only screen and (max-width: 600px) {
    nav ul {
        flex-direction: column;
    }

    nav ul li {
        margin: 10px 0;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.8rem;
    }

    p {
        font-size: 1rem;
    }

    section {
        padding: 20px 15px;
        margin: 15px auto;
    }

    .profile-photo {
        width: 120px; /* Smaller size for mobile */
        height: 120px;
        margin-bottom: 20px;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .social-links a {
        font-size: 2rem;
        margin: 0 10px;
    }
}

@media only screen and (min-width: 601px) and (max-width: 992px) {
    nav ul li {
        margin: 0 10px;
    }

    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
}
