body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    padding-bottom: 100px;
    box-sizing: border-box;
}

header {
    background-image: url('images/auroraheader.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 10px;
    text-align: center;
}

nav ul {
    list-style-type: none;
    padding: 0;
}

nav ul li {
    display: inline;
    margin-right: 15px;
}

nav ul li a {
    color: white;
    text-decoration: none;
}

.profile-container {
    display: flex;
    align-items: flex-start;
    margin-top: 20px;
}

.profile-picture {
    width: 120px;
    height: 120px;
    /* border: 2px solid #000; */
    border-radius: 50%; /* makes circular */
    margin-right: 20px;
    /* object-fit: cover; */
    max-width: 100%;
}

.about-text {
    max-width: 600px;
}

section {
    margin: 20px auto;
    padding: 0 20px;
    max-width: 1200px;
}

/* Flexbox for case section */
.case-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-top: 20px;
}

.case-text {
    flex: 1;
    margin-right: 20px;
}

.case-image img {
    max-width: 300px; /* Adjust image width */
    height: auto;
}

.small-image {
    max-width: 300px;
    width: 100%;
    height: auto; /* Keeps aspect ratio */
}

.medium-image {
    max-width: 600px;
    width: 100%;
    height: auto;
}

.large-image {
    max-width: 800px;
    width: 100%
    height:auto;
}

footer {
    background-image: url('/images/auroraheader.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
    padding: 10px;
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 60px; /* define explicit height */
}

.citation {
    font-family: "Times New Roman", Times, serif;
    font-size: 14px;
    margin-bottom: 15px;
}

.photo-row {
    display: flex;
    justify-content: center;
    gap: 20px;          /* space between images */
    margin: 40px 0;     /* space above and below the row */
}

.photo-row img {
    width: 30%;         /* 3 images per row on larger screens */
    max-width: 300px;
    border-radius: 10px; /* optional rounded corners */
    object-fit: cover;
}

/* --- Portfolio Grid Layout --- */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 1.5rem;
}

/* --- Individual Project Card --- */
.portfolio-item {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
    text-align: center;
}

.portfolio-item:hover {
    transform: translateY(-6px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.15);
}

/* --- Thumbnails --- */
.portfolio-item img.thumb {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}

/* --- Titles --- */
.portfolio-item h3 {
    font-size: 1.25rem;
    margin: 0.75rem 0 0.5rem;
    color: #003366; /* dark blue, adjust to match your palette */
}

/* --- Description Text --- */
.portfolio-item p {
    font-size: 0.95rem;
    line-height: 1.5;
    padding: 0 1rem 1.25rem;
    color: #444;
}

/* --- Links --- */
.portfolio-item a {
    text-decoration: none;
    color: inherit;
}

.portfolio-item a:hover h3 {
    color: #0077cc; /* highlight on hover */
}

/* --- Section Headings --- */
main section h2 {
    font-size: 1.5rem;
    margin-top: 2rem;
    border-bottom: 2px solid #ddd;
    padding-bottom: 0.25rem;
}

.bio-photo img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    display: block;
    margin: 0 auto;
}

/* --- Hi I'm Cait section --- */
.profile-container {
    display: flex;
    align-items: flex-start; /* aligns top edges of pic + text */
    gap: 1.5rem;
    margin-top: 1rem;
    flex-wrap: wrap; /* stacks on smaller screens */
}

.profile-picture {
    max-width: 180px; /* keeps profile image tidy */
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.about-text {
    flex: 1; /* takes remaining space */
    display: flex;
    align-items: center; /* vertically centers text with image/title */
}
.about-text p {
    margin: 0;
}

.intro-container {
    display: flex;
    align-items: center;  /* vertically center image+text */
    gap: 1.5rem;
    flex-wrap: wrap;      /* stack on smaller screens */
    margin-top: 1rem;
}

.intro-left {
    display: flex;
    flex-direction: column;
    align-items: center; /* centers h2 above img */
}

.intro-left h2 {
    margin-bottom: 0.5rem;
}

.intro-right {
    flex: 1;
}

/* --- Intro Layout --- */
.intro-container {
    display: flex;
    align-items: center; /* vertically centers photo + text */
    gap: 1.5rem;
    flex-wrap: wrap;     /* stacks nicely on small screens */
    margin-top: 1rem;
}

.intro-left img.profile-picture {
    max-width: 180px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.intro-right {
    flex: 1;
}

.intro-right h2 {
    margin: 0 0 0.5rem 0; /* keeps tight spacing above paragraph */
}

/* Contain floats inside Bio section */
.bio-section::after {
    content: "";
    display: table;
    clear: both;
}

.bio-photo.second {
    clear: right; 
    float: left;
}

/* Ensure main content has space for fixed footer */
body {
    padding-bottom: 80px; /* matches footer height */
}

/* Desktop: float images left with buffer */
.bio-photo {
    max-width: 340px;
    margin: 1rem 1.5rem; 
    float: right;
    clear: both;
    display: block;
}

.contact-photo {
    max-width: 340px;
    margin: 1rem 1.5rem; 
    float: left;
    clear: both;
    display: block;
}

/* Stack vertically on smaller screens and mobile */
@media (max-width: 768px) {
    .photo-row {
        flex-direction: column;
        align-items: center;   /* center the stacked images */
    }

    .photo-row img {
        width: 80%;            /* make them bigger when stacked */
        max-width: 400px;
    }
}
/* Mobile/smaller screens: center images with spacing */
@media (max-width: 768px) {
    .bio-photo {
        float: none;
        margin: 1.5rem auto;  /* centers image with vertical buffer */
        display: block;
    }
    .bio-photo.second {
        float: none;
    }
    .contact-photo {
        float: none;
        margin: 1.5rem auto;
    }
}

.footer-spacer {
    clear: both;            /* clears the floats */
    height: 100px;          /* match or slightly exceed footer height */
}

/* --- Bibliography Styling --- */
.csl-bib-body {
    line-height: 1.5;
    margin: 1.5rem 2rem;
    font-size: 0.95rem;
    color: #222;
}

.csl-entry {
    margin-bottom: 1rem;
    text-indent: -1.5em;   /* hanging indent */
    margin-left: 1.5em;    /* aligns properly after indent */
}

.csl-entry i {
    font-style: italic;
    color: #333;
}

.csl-entry a {
    color: #0066cc;
    text-decoration: none;
    margin-left: 0.5rem;
    font-size: 0.9rem;
}

.csl-entry a:hover {
    text-decoration: underline;
    color: #004999;
}
