body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    display: flex; /* Enable Flexbox */
    flex-direction: column; /* Stack header, main, and footer vertically */
    min-height: 100vh; /* Ensure the body takes up the full height of the viewport */
    background-color: #FFFFFF; /* White */
}

header {
    background-color: #3c3c3b;
    color: #fff;
    padding: 30px 50px;
}

header h1 {
    font-size: 2rem; /* Adjust size of the title */
    margin: 0;
}

header h1 a {
    text-decoration: none; /* Remove underline from title link */
    color: #fff;
}

nav {
    display: flex; /* Flex layout for left and right alignment */
    justify-content: space-between; /* Space out left and right sections */
    align-items: center; /* Vertically align items */
    margin-top: 20px; /* Add spacing between the title and navigation */
}

.nav-left {
    display: flex;
    align-items: center;
}

.nav-right {
    text-align: right; /* Align the text to the right */
    margin-right: -15px; /* Slightly shift the quote to the right */
    max-width: 40%; /* Prevent the quote from stretching too far */
    flex-shrink: 0; /* Prevent the quote from squishing when resizing */
}

.nav-right .support-link {
    color: #fff; /* White by default, like other navbar text */
    text-decoration: none; /* Remove underline by default */
    font-size: 1rem; /* Ensure it matches navbar text size */
    font-style: italic; /* Add emphasis for link text */
    display: inline-flex; /* Align icon and text inline */
    align-items: center; /* Vertically align icon with text */
    margin-left: 10px; /* Add subtle spacing from adjacent navbar items */
}

.nav-right .support-link i {
    font-size: 0.85rem; /* Slightly smaller icon for visual balance */
    margin-left: 5px; /* Add spacing between text and icon */
}

.nav-right .support-link:hover {
    color: #ecc05b; /* Highlight color on hover */
}

.nav-right .support-link:hover i {
    color: #ecc05b; /* Match icon hover color to text */
}

nav a {
    color: #fff;
    margin-right: 20px;
    text-decoration: none; /* Remove all underlining */
    font-size: 1rem; /* Adjust text/icon size */
    line-height: 1.5; /* Matches text and icon alignment */
    font-weight: 400; /* Set a base font-weight for consistency */
}

/* Icons: Ensure they inherit hover styles */
nav a i {
    font-size: 1.2rem; /* Slightly larger for better visibility */
    vertical-align: middle; /* Align icons nicely with text */
}

/* Hover effect: Highlight both text and icons */
nav a:hover {
    color: #ecc05b; /* Add a highlight color to text */
}

nav a:hover i {
    color: #ecc05b; /* Ensure icons match hover color */
}

/* Keep clicked (active) buttons in highlighted color */
nav a.active {
    color: #ecc05b;
    font-weight: 700; /* Bolder weight for the active link */
}

/* Ensure icons in clicked (active) links match text color */
nav a.active i {
    color: #ecc05b;
}

main {
    flex: 1; /* Allow the main content to expand and fill available space */
    padding: 30px 140px; /* Default padding */
    color: #090c02; /* Dark gray text color */
}

.about-container {
    display: flex; /* Align text and photo side-by-side */
    justify-content: space-between; /* Add space between text and photo */
    gap: 50px; /* Adjust spacing between text and photo */
    align-items: flex-start; /* Align the top of the photo and text */
}

.about-text {
    flex: 2; /* Make the text area take up more space */
    font-size: 1rem; /* Adjust font size */
    line-height: 1.6; /* Improve readability */
    color: #090c02;
    text-align: justify; /* Justify the text */
}

.about-photo {
    flex: 1; /* Make the photo area smaller */
    max-width: 300px; /* Control maximum image size */
    margin-top: 30px; /* Increase distance from the header */
}

.about-photo img {
    max-width: 100%; /* Ensure the image is responsive */
    height: auto; /* Maintain aspect ratio */
    border-radius: 0px; /* Optional: Add rounded corners to the photo */
    margin-right: 50px; /* Match the text's left padding */
}

/* Projects container */
.projects-container {
    display: flex;
    flex-direction: column; /* Stack project entries vertically */
    gap: 30px; /* Space between each project entry */
    margin-top: 20px;
}

/* Individual project entry */
.project-entry {
    display: flex; /* Align project title and icon side-by-side */
    justify-content: space-between; /* Separate the text and image */
    align-items: center; /* Center-align icon with text */
    border-bottom: 1px solid #ccc; /* Optional: Add a divider between projects */
    padding-bottom: 20px; /* Space under the divider */
}

/* Project info (title and caption) */
.project-info {
    flex: 1; /* Allow text area to take up remaining space */
    max-width: 60%; /* Limit width of the text block */
}

.project-title {
    font-size: 1.2rem; /* Larger text for titles */
    font-weight: bold; /* Make titles stand out */
    text-decoration: none; /* Remove underline for links */
    color: #000; /* Default title color */
    transition: color 0.3s ease; /* Smooth color transition on hover */
}

.project-title:hover {
    color: #00AFB5; /* Highlight color on hover */
}

.project-caption {
    font-size: 1rem;
    color: #555; /* Subtle color for captions */
    margin-top: 5px; /* Add spacing between title and caption */
}

/* Project icon (image) */
.project-icon {
    flex: 0 0 100px; /* Fixed size for icons */
    width: 100px;
    height: 100px;
    overflow: hidden; /* Prevent large images from spilling out */
}

.project-icon img {
    width: 100%; /* Ensure images fit the container */
    height: 100%; /* Crop to fit square dimensions */
    object-fit: cover; /* Ensure images are cropped proportionally */
    border-radius: 8px; /* Optional: Rounded corners for icons */
}

/* Photos container */
.photos-container {
    display: flex;
    flex-direction: column; /* Stack photo entries vertically */
    gap: 30px; /* Space between each experience */
    margin-top: 20px;
}

/* Individual photo entry */
.photo-entry {
    display: flex; /* Align text and photo grid side-by-side */
    justify-content: space-between; /* Separate the text and photo grid */
    align-items: flex-start; /* Align the top of the text and grid */
    border-bottom: 1px solid #ccc; /* Optional: Divider between experiences */
    padding-bottom: 20px;
}

/* Left-side text */
.photo-info {
    flex: 1;
    max-width: 40%; /* Limit width of text block */
}

.photo-info h2 {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 10px;
    color: #000;
}

.photo-info p {
    font-size: 1rem;
    color: #555;
    line-height: 1.6;
}

/* Right-side image grid */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 columns */
    grid-auto-rows: 1fr; /* Consistent row heights */
    gap: 10px; /* Space between thumbnails */
    padding: 0; /* Remove unnecessary padding */
    box-sizing: border-box; /* Include padding in dimensions */
    align-items: center; /* Vertically center grid items, including error message */
}

.photo-grid a {
    display: block;
    position: relative;
    overflow: hidden; /* Prevent content overflow */
    width: 100%; /* Let the grid define the width */
    height: 80px; /* Adjust thumbnail height */
}

.photo-grid img {
    width: 100%; /* Fill the grid cell */
    height: 100%; /* Match the grid cell height */
    object-fit: cover; /* Ensure proper cropping */
}

.photo-grid img:hover {
    transform: scale(1.05); /* Slight zoom on hover */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.photo-grid-error {
    margin: 0; /* Remove default margins */
    padding: 0; /* Ensure no internal padding */
    text-align: left; /* Align text to the left */
    color: red; /* Maintain warning color */
    font-size: 1rem; /* Ensure readability */
    grid-column: 1 / -1; /* Span the entire grid width */
    justify-self: start; /* Align the error message to the left */
    align-self: center; /* Vertically center the error message */
}

/* Lightbox Overlay */
.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8); /* Semi-transparent background */
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0; /* Start invisible */
    visibility: hidden; /* Hide overlay */
    transition: opacity 0.3s ease, visibility 0.3s ease; /* Fade-in/out */
    z-index: 1000;
}

.lightbox-overlay.active {
    opacity: 1; /* Fully visible */
    visibility: visible; /* Make overlay visible */
}

/* Lightbox Image */
.lightbox-image {
    max-width: 80%; /* Slightly smaller than before */
    max-height: 80%; /* Maintain aspect ratio */
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5); /* Add shadow */
    transition: none; /* Remove zoom effect */
}

/* Close Icon */
.lightbox-close {
    position: absolute;
    top: 10px;
    right: 10px;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 1001; /* Above the image */
    background: rgba(0, 0, 0, 0.5);
    border: none;
    padding: 5px 10px;
    border-radius: 5px;
}

/* Navigation Arrows */
.lightbox-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 2rem;
    cursor: pointer;
    z-index: 1001; /* Above the image */
    background: rgba(0, 0, 0, 0.5);
    border: none;
    padding: 5px 10px;
    border-radius: 5px;
}

.lightbox-arrow.left {
    left: 10px; /* Position on the left edge */
}

.lightbox-arrow.right {
    right: 10px; /* Position on the right edge */
}

footer {
    background-color: #3c3c3b;
    color: #fff;
    text-align: center;
    padding: 15px 0;
    margin-top: 0; /* Remove unnecessary margin to keep it at the bottom */
}

.construction-message {
    text-align: center;
    padding: 50px;
    background-color: #f9f9f9;
    color: #333;
}
.construction-message h1 {
    color: #FF6600;
}
.construction-message a.btn {
    color: #ffffff;
    background-color: #0072BC;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
}

/* Responsive Design */
@media (max-width: 768px) { /* For smaller screens */
    main {
        padding: 20px 10px; /* Reduce padding for smaller screens */
    }
    .nav-right {
        display: none; /* Hide the quote on small screens for better usability */
    }
    .about-container {
        flex-direction: column; /* Stack text and photo vertically */
        gap: 15px; /* Reduce spacing for smaller screens */
    }
    .about-photo {
        align-self: center; /* Center the photo on small screens */
        margin-right: 0; /* Remove extra right margin on smaller screens */
    }
}
