/* General styles */
html, body {
    height: 100%;
    margin: 0;
    scroll-behavior: smooth; /* Smooth scrolling */
}

body {
    display: flex;
    flex-direction: column;
    font-family: Arial, sans-serif;
    overflow-x: hidden; /* Prevent horizontal overflow */
    background-color: #f5f5f5;
}

/* Sidebar styles */
.sidebar {
    width: 250px;
    height: 100vh;
    background-color: #333;
    color: #fff;
    position: fixed;
    left: 0;
    top: 0;
    display: flex;
    flex-direction: column;
    padding-top: 20px;
    align-items: center; /* Center content horizontally */
    overflow-y: auto; /* Add scroll if content overflows */
    transition: transform 0.3s ease; /* Smooth transition for collapsing */
    transform: translateX(0); /* Show sidebar by default */
}

/* Sidebar toggle button */
.sidebar-toggle {
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 24px;
    color: #fff;
    background: #333;
    border: none;
    cursor: pointer;
    display: block; /* Always display */
}

/* Sidebar content */
.profile {
    text-align: center;
}

.profile img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 3px solid white;
}

.profile h2 {
    margin: 10px 0;
    font-size: 24px;
    letter-spacing: 0.1em;
}

.social-links {
    display: flex;
    align-items: center;
    justify-content: center;
}

.social-icon {
    color: #fff;
    font-size: 15px;
    background-color: #d9d4d4;
    border-radius: 50%;
    width: 15px;
    height: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    margin: 10px;
    text-decoration: none;
    transition: background-color 0.3s, color 0.3s;
}

.social-icon:hover {
    background-color: #bbb;
    color: #000;
}

/* Navigation styles */
nav ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

nav ul li {
    margin: 15px 0;
}

nav {
    display: flex;
    flex-direction: column;
    width: 250px;
}

nav ul li a {
    color: #fff;
    text-decoration: none;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    transition: background 0.3s;
    padding-left: 20px;
}

nav ul li a i {
    margin-right: 10px;
}

nav ul li a:hover {
    background-color: #575757;
}

/* Menu icon (shown on smaller screens, hidden on large) */
.menu-icon {
    display: none; /* Hidden by default */
    font-size: 24px;
    cursor: pointer;
    width: 40px; /* Diameter of the circle */
    height: 40px; /* Diameter of the circle */
    border-radius: 50%; /* Circle shape */
    background-color: #333; /* Background color */
    position: fixed;
    top: 20px;
    right: 20px; /* Positioned in the top right corner */
    z-index: 1001; /* Ensure it's on top of other content */
    isplay: flex; /* Flexbox for centering */
    align-items: center; /* Center vertically */
    justify-content: center; /* Center horizontally */
}

.menu-icon i {
    font-size: 24px;
    color: #f5f3f2;
    margin-top: 9px;
    margin-left: 9px;
}

.menu-icon:hover {
    background-color: #636262;
}

/* Page styles */
.page {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* Ensure the page takes up at least the full viewport height */
    background-color: #f5f5f5;
    color: #333;
    padding: 24px;
    padding-left: 40px;
    gap: 20px;
}

/* Ensure the main content takes up available space */
.main-content {
    margin-left: 250px;
    flex: 1;
    gap: 20px;
}

.page h1 {
    color: #333;
}

p {
    font-weight: normal;
}

.portfolio-item h3 {
    text-align: left;
    text-decoration: underline;
}

.portfolio-item p {
    text-align: left;
}

.details h4 {
    text-align: left;
}

.details p {
    text-align: left;
    font-weight: normal;
}

#home {
    justify-content: center;
}

/* Container for portfolio items */
.portfolio-items {
    display: grid;
    gap: 16px; /* Space between items */
    grid-template-columns: repeat(2, 1fr); /* Default to two columns */
}

/* Style for each portfolio item */
.portfolio-item {
    box-sizing: border-box;
    text-align: center;
}

/* Responsive images */
.portfolio-item img {
    width: 100%; /* Scale to container width */
    height: auto; /* Maintain aspect ratio */
    max-width: 100%; /* Ensure image does not exceed its container */
    display: block; /* Remove extra space below the image */
}


/* Resume section styles */
#resume {
    display: flex;
    flex-direction: column;
    padding-left: 24px;
    gap: 20px;
}

#resume h2 {
    font-size: 2em;
    margin-bottom: 20px;
}

.resume-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.resume-column {
    padding: 10px;
}

h1 {
    font-size: 48px;
    text-align: center;
    letter-spacing: 0.1em;
}

h2 {
    font-size: 2em;
    letter-spacing: 0.1em;
}

h3, h5, p {
    letter-spacing: 0.1em;
}

.resume-columns ul li {
    font-weight: normal;
}

h5.course {
    font-weight: bold; /* Ensures the font is bold */
}


p.para {
    font-size: 24px;
    text-align: center;
}

.date {
    font-weight: bold;
}

.about, .portfolio {
    margin: 16px 0;
}

#services ul li {
    font-weight: normal;
}

/* Ensure .contacts-container is a column flex container */
.contacts-container {
    display: flex;
    flex-direction: column;
    gap: 20px; /* Add space between items */
}

/* Ensure .location-container items are spaced and aligned properly */
.location-container {
    display: flex;
    align-items: center;
    gap: 10px; /* Space between icon and text */
}

/* Ensure form inputs are styled properly */
#contact-form {
    display: flex;
    flex-direction: column;
    gap: 10px; /* Space between form elements */
}

#contact-form label {
    font-weight: bold;
}

#contact-form {
    /* Optional: You can add styles here to further refine the form */
    padding-top: 20px; /* Add space between form and above elements */
}

#contact-form input,
#contact-form textarea {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

#contact-form button {
    padding: 10px;
    background-color: #333;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

#contact-form button:hover {
    background-color: #575757;
}

/* Style for location container */
.location-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Style for the font awesome icons */
.icon i {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #ddd;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    padding: 8px;
    margin-right: 8px;
    font-size: 24px;
    color: black;   
}

/* Hover effect for the icons */
.icon:hover i {
    color: #8a8887;
}

/* Style for location texts */
.location-text {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.location-label {
    font-weight: bold;
    color: #333;
    margin: 0;
    font-size: 22px;
}

.location-name {
    color: #333;
    font-weight: normal;
    margin: 0;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4); /* Black w/ opacity */
}

/* Modal Content */
.modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 15px;
    border-radius: 10px;
    border: 1px solid #333;
    width: 80%;
}

/* Style the footer */
footer {
    background-color: #f5f5f5;
    color: #333;
    text-align: center;
    padding: 10px;
    font-size: 14px;
    margin: 0;
}

/* Responsive Styles */
@media (max-width: 992px) {
    .main-content {
        margin-left: 250px; /* Keep space for sidebar */
    }

    .portfolio-items {
        grid-template-columns: 1fr; /* One column */
    }

    .resume-columns {
        grid-template-columns: 1fr; /* Switch to single-column */
    }

    .page {
        padding: 20px;
    }

    #resume {
        padding: 20px;
    }
}

@media (max-width: 768px) {
    .main-content {
        margin-left: auto; /* Remove margin */
    }


    .page {
        padding: 16px;
    }

    #resume {
        padding: 16px;
    }

    .portfolio-items {
        grid-template-columns: 1fr; /* Ensure single column layout */
    }

    .sidebar {
        transform: translateX(-250px); /* Hide sidebar initially */
    }

    .sidebar.sidebar-open {
        transform: translateX(0); /* Slide in */
    }

    .menu-icon {
        display: block; /* Show menu icon */
    }
}

/* Add styles for screens below 478px */
@media (max-width: 485px) {
    .main-content {
        margin-left: 0; /* Remove margin to fit content */
    }

    .menu-icon {
        font-size: 24px; /* Adjust icon size if needed */
    }


    .page {
        padding: 12px;
    }

    #resume {
        padding: 12px;
    }

    .profile img {
        width: 100px; /* Adjust profile image size if needed */
        height: 100px;
    }

    .portfolio-items {
        grid-template-columns: 1fr; /* Ensure single column layout */
    }

    .resume-columns {
        grid-template-columns: 1fr; /* Switch to single-column */
    }

    .icon i {
        margin-right: 4px;
    }

    .location-name {
    font-size: 0.9em;
}
}

/* Responsive Styles for screens below 365px */
@media (max-width: 365px) {
    .sidebar {
        padding-top: 15px; /* Further reduced padding */
    }

    .page {
        padding: 8px;
    }

    #resume {
        padding: 8px;
    }

    .main-content {
        margin: 0; /* Remove margin to center content properly */
        width: 100%; /* Full width to utilize available space */
        box-sizing: border-box; /* Include padding in width calculation */
    }

    .profile {
        text-align: center; /* Center profile content */
    }

    .profile img {
        width: 80px; /* Adjust profile image size */
        height: 80px;
        margin: 0 auto; /* Center the image */
    }

    h1 {
        text-align: center; /* Center heading text */
    }
    p.para {
        text-align: center; /* Center paragraph text */
    }

    .location-label {
        text-align: center; /* Center location label text */
    }

    .location-name {/
        text-align: center; /* Center location name text */
    }

.location-label {
    text-align: left;
}

.location-name {
    font-size: 0.9em;
}

    footer {
        text-align: center; /* Center footer text */
    }
}

/* Responsive Styles for screens below 365px */
@media (max-width: 350px) {
    .page {
        padding: 8px;
    }

    #resume {
        padding: 8px;
    }

    .main-content {
        margin: 0; /* Remove margin to center content properly */
        width: 100%; /* Full width to utilize available space */
        box-sizing: border-box; /* Include padding in width calculation */
    }

.location-label {
    text-align: left;
    font: 1em;
}

.location-name {
    font-size: 0.9em;
}