body {
    font-family: 'Roboto', sans-serif;
    max-width: 90%; /* Limit overall width */
    margin: 0 auto !important; /* Center content */
    padding: 0 20px; /* Add breathing room on sides */
}

h1, h2, h3, h4, h5, h6{
    font-family: 'Merriweather', serif;
}
p {
    font-size: 16px;
    line-height: 1.5;
    padding: 0 5px;    /* Add horizontal padding to paragraphs */
    margin: 1rem 0; 
}
li {
    margin-bottom: 10px;
}
h1 {
    font-size: 24px;
    margin: 20px 0 0 0; /* top right bottom left */
    padding: 8px 0 0 0;
}
h1.text-center{
    color: #75021f;
}
h2 {
    font-size: 20px;
}
h3 {
    font-size: 18px;
}
div{
    width: auto;
    margin: auto;
}
a {
    color: blue;
    text-decoration: none;
}
a:visited {
    color: purple;
}
a:hover {
    color: #e74488; /* I like this color, but it's too pale on the pink background ec73a6 */
    text-decoration: underline;
}
figcaption {
    font-size: 14px;
    width: fit-content;
}
table {
    table-layout: fixed;
    width: 100%;
}

/* Target specific columns using nth-child */
td:nth-child(1), th:nth-child(1) {
    width: 25%; /* Character Name column */
}

td:nth-child(2), th:nth-child(2) {
    width: 30%; /* System column - wider for long text */
}

td:nth-child(3), th:nth-child(3) {
    width: 30%; /* Campaign column */
}

td, th {
    word-wrap: break-word;
    padding: 4px;
}
figure img {
    border-radius: 10px 10px 0 0;
}
footer {
    background-color: lemonchiffon;
    width: fit-content;
}
caption {
    caption-side: top; /* Places caption above the table */
}
.content-bubble {
    border-radius: 15px;
    padding: 20px;
    margin: 20px 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    height: 100%;
}
.bubble-blue {
    background-color: #e6f3ff; /* #f0f8ff could also work, it's a bit lighter. I'm going to waffle about it I'm sure */;
}
.bubble-pink {
    background-color: #fff0f3 /* #fce4ec could also work, it's a bit lighter. I'm going to waffle about it I'm sure */;
}
.bubble-white {
    background-color: #f8f9fa;
}
.container {
    padding: 20px 3rem; /* Consistent inner spacing */
    margin: 20px auto; /* Vertical spacing between containers */
}

.navbar-nav .nav-link,
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:active,
.navbar-nav .nav-link.active {
    color: #9c1157; /* Using your existing maroon color */
}
.navbar-brand,
.navbar-brand:hover,
.navbar-brand:active
.navbar-brand.active {
    color: #75021f !important;
}

/* Add to style.css */
.navbar-brand,
.navbar-nav .nav-link {
    font-weight: 700;
}

/* Add to style.css */
p.small {
    margin-bottom: 0.5rem; /* Reduce bottom margin */
}

.navbar {
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
}

.ratio {
    width: 100%;
    max-width: 100%;
    margin-bottom: 1rem;
}

.list-header {
    font-weight: bold;
    list-style-type: none;
    margin-left: -1.5em;
}

/* Add to style.css */
ul li ul {
    margin-top: 0.5rem;      /* Add space above nested list */
    padding-left: 1.5rem;    /* Indent nested list */
    margin-bottom: 0.5rem;   /* Space below nested list */
}
/* This is needed for the list in index.html*/
.content-bubble ol {
    padding-left: 40px; /* Restore default left padding */
    margin: 0; /* Reset margin */
}

/* Reset flex settings */
.row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -0.5rem;  /* Bootstrap gutter compensation */
    margin-left: -0.5rem;   /* Bootstrap gutter compensation */
}

/* Column settings */
.col-md-6, .col-md-4 {
    margin-bottom: 1rem;
    display:  flex;
    flex-direction: column;
}
/* Add to style.css */
.citation {
    padding-left: 2em;      /* Space for hanging indent */
    text-indent: -2em;      /* Pull first line left */
    margin-bottom: 0.5em;   /* Space between citations */
}
ul {
    list-style-type: disc;
}
.custom-bullets {
    list-style-type: none;;
}
li.custom-bullets::before {
    content: "-";
    color: #000000;
    margin-left: -1.2em;   /* Pull bullet back to match disc */
    margin-right: 0.5em;   /* Space between bullet and text */
    display: inline-block;
    width: 1em;           /* Consistent bullet width */
}

/* Add to style.css */
.card {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;     /* Contain all content */
}

/* Add to style.css */
.card-body {
    display: flex;
    flex-direction: column;
    flex: 1;
}

/* Add to style.css */
.card-title, 
.card-text {
    margin-bottom: 0;       /* Remove bottom margin from text elements */
}

/* Add to style.css */
.card-text {
    flex-grow: 1;
    margin-bottom: 0;
    margin-top: auto;
}

/* Add to style.css */
.card-img-top {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

/* Add to style.css */
.row-cols-md-2 > .col {
    display: flex;
    margin-bottom: 1rem;
}

.carousel {
    flex: 1 1 auto;     /* Allow carousel to flex */
    height:100%;
    width: 100%;
    aspect-ratio: 5/7;    /* Force consistent ratio */
}

/* Add to style.css */
.card .carousel {
    max-height: 400px;    /* Set max height */
    overflow: hidden;      /* Contain overflow */
}

.card .carousel-item {
    height: 400px;        /* Match carousel height */
}

.card .carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;   /* Preserve aspect ratio */
}

.carousel-inner {
    width: 100%;
    height: 100%;         /* Fill container */
}

.carousel-item {
    width: 100%;
    height: 100%;         /* Fill container */
}

.carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;  /* Preserve aspect ratio */
    object-position: center;
}

/* Add to style.css */
.content-bubble.current-projects {
    margin-bottom: 0;
    padding-bottom: 0;
}

/* Add to style.css */
.content-bubble.publications {
    margin-top: 0;
    padding-bottom: 0;
}

/* Add to style.css */
.row .education,
.row .academic {
    margin-bottom: 4px;
}
/* Add to style.css */
.content-bubble h4,
.content-bubble h5 {
    text-decoration: underline;
}
iframe {
    padding: 0 5px;
}

/* Add to style.css */
.content-bubble .section-divider {
    border: 0;
    border-top: 2px solid #9c1157;
    width: 50%;
    margin: 1rem auto;
}
.sub-header {
    font-style: italic;
    list-style-type: none;
    margin-left: -1.5em;
}

/* Add to style.css */
.no-margin {
    margin-bottom: 0;
}
.no-margin-top {
    margin-top: 0;
}

/* Add to style.css */
.content-bubble.no-flex {
    display: block;          /* Override flex display */
    height: auto;           /* Auto height instead of 100% */
    flex: none;            /* Remove flex properties */
}

/* Add to style.css */
.carousel {
    height:100%;
    width: 100%;
    aspect-ratio: 5/7;    /* Force consistent ratio */
}

.carousel-inner {
    width: 100%;
    height: 100%;         /* Fill container */
}

.carousel-item {
    width: 100%;
    height: 100%;         /* Fill container */
}

.carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;  /* Preserve aspect ratio */
    object-position: center;
}

.grid-margin {
    margin-bottom: 16px;
}

a.contrast-fix {
    color: #ffffff;
}
/* Pagination styles */
.page-tabs {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.gallery-page {
  display: none;
}

#page1:checked ~ .gallery-container .page-1,
#page2:checked ~ .gallery-container .page-2 {
  display: block;
}

.pagination {
  display: flex;
  justify-content: center;
  list-style: none;
  padding: 0;
  margin: 1rem 0;
}

.pagination label {
  padding: 0.5rem 1rem;
  margin: 0 0.25rem;
  border: 1px solid #dee2e6;
  border-radius: 0.25rem;
  cursor: pointer;
}

.pagination label:hover {
  background-color: #f8f9fa;
}

#page1:checked ~ .pagination .page1-label,
#page2:checked ~ .pagination .page2-label {
  background-color: #0d6efd;
  color: white;
}
.bubble-pink > .row > .col-md-12.bubble-white {
    margin-left: 3%;
    margin-right: 3%;
    width: 94% !important;
}
.content-bubble.container {
    width: 100% !important;
    max-width: none !important;
    padding-left: 20px !important;
    padding-right: 20px !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}