/* General Page Reset */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #f4f4f5;
    color: #333;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    display: flex;
    justify-content: center;
}

/* The Main Container */
.container {
    background-color: #ffffff;
    width: 100%;
    max-width: 600px;
    margin: 40px 20px;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

/* Header & Profile Picture */
header {
    text-align: center;
    margin-bottom: 30px;
}

.profile-pic {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 15px;
}

h1 {
    margin: 0;
    font-size: 2em;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.subtitle {
    color: #666;
    margin-top: 5px;
    font-size: 1.1em;
}

/* Main Navigation Buttons */
nav {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap; /* Allows buttons to stack on small screens */
    margin-bottom: 30px;
}

.button {
    text-decoration: none;
    background-color: #333;
    color: white;
    padding: 10px 15px;
    border-radius: 4px;
    font-size: 0.9em;
    font-weight: 600;
    transition: background-color 0.2s;
    min-width: 100px; /* Ensures buttons have consistent width */
    text-align: center;
}

.button:hover {
    background-color: #F54927;
}

/* Sections */
section {
    margin-bottom: 30px;
}

h2 {
    font-size: 0.9em;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #888;
    margin-bottom: 15px;
    font-weight: 700;
}

hr {
    border: 0;
    border-top: 1px solid #eee;
    margin: 30px 0;
}

/* Link List (Current Projects) */
.link-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.link-list li {
    margin-bottom: 10px;
}

.link-list a {
    display: block;
    text-decoration: none;
    color: #333;
    background-color: #fafafa;
    padding: 15px;
    border-radius: 6px;
    border: 1px solid #eee;
    font-weight: 500;
    transition: all 0.2s;
}

.link-list a:hover {
    background-color: #f0f0f0;
    border-color: #ddd;
    padding-left: 20px;
}

/* Connect Section (Socials) */
.social-row {
    text-align: center;
    font-size: 1.1em;
}

.social-row a {
    color: #333;
    text-decoration: none;
    font-weight: 600;
    border-bottom: 2px solid transparent;
    transition: border-bottom 0.2s;
}

.social-row a:hover {
    border-bottom: 2px solid #333;
}

.separator {
    margin: 0 10px;
    color: #ccc;
}

/* Footer */
footer {
    text-align: center;
    font-size: 0.8em;
    color: #aaa;
    margin-top: 40px;
}

/* Mobile Tweak */
@media (max-width: 600px) {
    .container {
        margin: 0;
        border-radius: 0;
        padding: 20px;
        box-shadow: none;
    }
    
    nav {
        flex-direction: column; /* Stack buttons vertically on very small phones */
    }
    
    .button {
        width: 100%; /* Full width buttons on mobile */
        box-sizing: border-box;
    }
}

/* --- Gallery Grid Styles --- */

.gallery-grid {
    display: grid;
    /* This magic line makes it responsive: 
       It creates columns that are at least 150px wide, 
       but stretch to fill available space. */
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px; /* Space between tiles */
    margin-top: 20px;
}

.gallery-tile {
    display: block; /* Makes the whole tile a link */
    aspect-ratio: 1 / 1; /* Forces the tile to be a perfect square */
    overflow: hidden; /* Hides image parts that stick out */
    border-radius: 8px; /* Rounded corners */
    position: relative; /* Needed for hover effects later */
    border: 1px solid #eee;
    transition: transform 0.2s ease;
}

/* Hover Effect: Slight Zoom */
.gallery-tile:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.gallery-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* CROPS the image to fill the square without distorting it */
    display: block;
}

/* --- Single Project Page Styles --- */

.full-width-img {
    width: 100%;
    height: auto; /* Maintains aspect ratio */
    border-radius: 8px;
    margin-bottom: 20px; /* Space between stacked images */
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}