body {
    font-family: 'Lora', serif;
    margin: 0;
    padding: 0px;
    background-color: #f0f0f0;
    height: 100%;
    width: 100%;
}
main {
    min-height: calc(100vh - 100px); 
    padding: 25px 50px !important;
}

/* Styles for the Nav Bar */
header {
    display: flex;
    align-items: center; 
    justify-content: space-between; 
    padding: 10px 20px;
    background-color: #c0101f;
    font-family: ivyepic;
    font-size: 20px;
    font-weight: 400;
}

h1 {
    font-size: 2.5em;
    margin: 0;
    padding-bottom: 10px;
}

nav {
    display: flex;
}

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

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

nav ul li a {
    color: #fff;
    text-decoration: none;
    font-size: 1.1em;
}

nav ul li a:hover {
    text-decoration: underline;
}

.nav-search-container {
    display: flex;
    flex-direction: row;
}

.search-input {
    padding: 6px;
    margin-top: 8px;
    font-size: 17px;
    border: none;
}

.search-button {
    position: relative;
    float: right;
    padding: 6px 10px;
    margin-top: 8px;
    margin-right: 10px;
    background: #808080;
    font-size: 17px;
    border: none;
    cursor: pointer;
}

.search-button:hover {
    background: #6e6e6e;
}

.search-button-text {
    color: white;
    transition: all 0.2s;
}

.open-sidebar-button {
    display: none;
    background: none;
    border: none;
    padding: 1em;
    margin-right: auto;
    cursor: pointer;
    color: white;
    font-size: 28px;
}

.close-sidebar-button {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 38px;
    font-weight: bolder;
    color: white;
    float: right;
}

#overlay {
    background: rgba(0, 0, 0, 0.2);
    position: fixed;
    inset: 0;
    z-index: 9;
    display: none;
}

@media (max-width: 790px) {
    .home-logo {
        display: none;
    }

    .open-sidebar-button,
    .close-sidebar-button {
        display: block;
    }
    
    nav {
        position: fixed;
        top: 0;
        left: -100%;
        height: 100vh;
        width: min(13.5em, 100%);
        z-index: 10;
        background-color: #c0101f;
        border-right: 1px solid #fff;
        transition: left 300ms ease-out;
    }

    nav.show {
        left: 0;
    }

    nav ul {
        padding-top: 10px;
        flex-direction: column;
        gap: 5px;
    }

    nav ul li {
        display: block;
        margin-right: 0px;
        font-size: 30px;
    }   

    nav a {
        width: 100%;
        padding-left: 1em;
    }
}

/* Styles for the Advanced Search Modal */
.open-advanced-search {
    padding: 6px 12px;
    margin-top: 8px;
    background: white;
    color: black;
    font-size: 17px;
    border: none;
    cursor: pointer;
    transition: background-color 0.1s ease-in-out;
}

.open-advanced-search:hover {
    background-color: #e9e9e9;
}

.open-modal {
    cursor: pointer;
}

.modal-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    display: none;
}

.modal-content {
    position: absolute;
    top: 100px;
    right: 20px;
    left: auto;
    background-color: #fff;
    border-radius: 5px;
    padding: 20px;
    display: inline-block;
    width: auto;
    max-width: 500px;
    min-width: 400px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    animation-name: slideIn;
    animation-duration: 0.3s;
    border: 1px solid #ddd;
}

.close-modal {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 28px;
    color: rgb(147, 147, 147);
    font-weight: bolder;
    font-family: Arial, Helvetica, sans-serif;
    transition: color 0.1s ease-in-out;
}

.close-modal:hover {
    color: black;
    cursor: pointer;
}

.advanced-search-title {
    font-size: 1.3em;
    font-weight: bold;
    color: #c0101f;
    margin: 0 0 20px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #c0101f;
}

.modal-search-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.modal-search-name {
    display: flex;
    flex-direction: column;
}

.modal-input-label {
    font-weight: bold;
    color: #444;
    font-size: 0.95em;
}

.modal-search-input-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-search-input {
    padding: 10px;
    border: 1px solid #d4d3d3;
    border-radius: 4px;
    font-size: 16px;
    margin-top: 15px;
}

.modal-search-input-container .modal-search-input {
    min-width: 60px;
    max-width: 80px;
}

.modal-date-separator {
    font-weight: bolder;
    font-size: 20px;
}

.advanced-search-button {
    position: relative;
    padding: 10px 20px;
    background-color: #c0101f;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-right: 10px;
    transition: background-color 0.1s ease-in-out;
}

.advanced-search-button:hover {
    background-color: #a00c1a;
}

.advanced-search-text {
    color: white;
    transition: all 0.2s;
}

.button-loading .advanced-search-text,
.button-loading .search-button-text {
    visibility: hidden;
    opacity: 0;
}

.button-loading::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    margin: auto;
    border: 4px solid transparent;
    border-top-color: white;
    border-radius: 50%;
    animation: button-loading-spinner 1s ease infinite;
}

@keyframes button-loading-spinner {
    from {
        transform: rotate(0turn);
    }

    to {
        transform: rotate(1turn);
    }
}

@keyframes slideIn {
    from {   
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@media (max-width: 1360px) {
    .nav-search-container {
        display: flex;
        flex-direction: column;
    }

    .search-input {
        font-size: 12px;
    }

    .search-button {
        font-size: 12px;
        margin-right: 0;
    }

    .open-advanced-search {
        font-size: 12px;
    }

    nav ul {
        gap: 15px;
    }

    nav ul li {
        margin-right: 0;
    }

    nav ul li a {
        font-size: 1em;
    }
}

@media (max-width: 1015px) {
    nav ul {
        gap: 10px;
    }

    nav ul li a {
        font-size: 0.7em;
    }
}

@media (max-width: 768px) {
    .modal-content {
        right: 10px;
        min-width: 300px;
        max-width: calc(100vw - 20px);
    }
}

@media (max-width: 480px) {
    .modal-content {
        right: 10px;
        left: 10px;
        min-width: auto;
        width: auto;
    }
}

 /* Styles for the Home Page */
.grey-box {
    background-color: rgb(65, 72, 97);
    padding: 40px 20px 40px 20px;
    width: auto;
}

.home-content {
    text-align: center;
    width: 100%;
}

.home-logo {
    max-width: 100%;
    height: auto;
    margin-top: 30px;
    margin-bottom: 30px;
}

.home-picture {
    max-width: 900px;
    min-width: 400px;
    width: 60%;
    height: auto;
    margin: 50px auto;
}

.home-text {
    color: rgb(255, 255, 255);
    font-size: 25px;
    line-height: 1.6;
    max-width: 900px;
    margin: 0 auto;
    text-align: left;
}

footer {
    background-color: #c0101f;
    color: #fff;
    text-align: center;
    padding: 10px 0;
    position: relative;
    bottom: 0;
    width: 100%;
    margin-top: auto;
}

.explore-section {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    margin-bottom: 130px;
}

.explore-title {
    font-size: 50px;
    text-align: center;
    margin-bottom: 2rem;
    font-family: serif;
}

.explore-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.explore-card {
    position: relative;
    aspect-ratio: 1;
    overflow: hidden;
}

.card-image {
    width: 100%;
    height: 100%;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 50, 0.7);
    padding: 1rem;
    color: white;
}

.card-overlay h2 {
    margin: 0;
    font-size: 20px;
    text-align: center;
    font-weight: lighter;
}

.card-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

@media (max-width: 700px) {
    .card-overlay {
        padding: 5px;
    }

    .card-overlay h2 {
        font-size: 15px;
    }
}

@media (max-width: 550px) {
    .home-text {
        font-size: 15px;
    }

    .explore-card {
        overflow: visible;
    }

    .card-image {
        display: none;
    }

    .card-overlay {
        display: flex;
        justify-content: center;
        align-items: center;
        height: 100%;
        width: 100%;
        padding: 0 10px;
    }
}

.about-page {
    margin-left: 60px;
    margin-top: 20px;
}

.woman_profile {
    float: right;
    max-width: 50%;
    height: auto;
    margin-top: 100px;
    margin-right: 100px;
}

/* Styles for the Search Results Page */
.search-results-container {
    margin: 10px 40px 30px 40px;
    display: flex;
    flex-direction: column;
}

.search-results-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-left: 12.5%;
    margin-bottom: 15px;
    font-size: 25px;
}

.search-results-container .pagination {
    margin-right: 15%;
    font-size: 18px;
}

.search-results-container p {
    font-weight: bold;
}

.search-results-container .women-table {
    width: 75%;
    margin: auto;
}

.search-results-container .women-table-cell {
    font-size: 20px;
}

.search-results-container .women-table-header {
    grid-template-columns: 1fr 1fr 1fr;
    font-size: 30px;
}

.search-results-container .women-table-row {
    grid-template-columns: 1fr 1fr 1fr;
}

.search-results-footer .pagination {
    margin-top: 15px;
    margin-right: 13%;
    float: right;
}

/* Styles for the Women List Page */
.women-list-container {
    display: flex;
    flex-direction: row;
    gap: 20px;
}

.women-list {
    flex: 2;
}

.table-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.list-title {
    font-size: 30px;
    font-weight: bold;
    margin: 0;
}

.women-table {
    width: 100%;
    margin-top: 30px;
    margin-bottom: 10px;
    background: white;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.women-table-header {
    display: grid;
    grid-template-columns: 120px 1fr 200px;
    gap: 20px;
    padding: 15px 20px;
    background-color: #f8f9fa;
    border-bottom: 2px solid #e2e4e7;
    font-weight: bold;
    font-size: 16px;
}

.women-table-header div {
    display: flex;
    justify-content: center;
    align-items: center;
}

.women-table-row {
    display: grid;
    grid-template-columns: 120px 1fr 200px;
    gap: 20px;
    padding: 15px 20px;
    border-bottom: 2px solid #e9ecef;
    align-items: center;
    transition: background-color 0.1s ease-in-out;
}

.women-table-row:nth-child(even) {
    background-color: #f8f9fa;
    transition: background-color 0.1s ease-in-out;
}

.women-table-cell {
    display: flex;
    align-items: center;
    justify-content: center;
}

.no-women-found {
    grid-column: 1 / 4;
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
    font-style: italic;
}

.photo-list {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 50%;
    display: block;
    margin: 0 auto;
}

.name-link {
    color: black;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.1s ease-in-out;
}

.name-link:hover {
    color: #c0101f;
}

.table-footer .pagination {
    float: right;
}

.pagination a {
    color: black;
    text-decoration: none;
    transition: color 0.1s ease-in-out;
}

.pagination a:hover {
    color: #c0101f;
}

.pagination span {
    font-weight: bold;
}

.search-container {
    flex: 1;
    margin-top: 66px;
    padding: 20px 35px 20px 20px;
    height: max-content;
    border: 1px solid #ddd;
    border-radius: 5px;
    background: #f9f9f9;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.search-title {
    font-size: 30px;
    font-weight: bold;
    margin: 0 0 15px 0;
}

.filter-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.filter-form label {
    font-weight: bold;
    margin-bottom: 5px;
    display: block;
}

.filter-text-input {
    width: 100%;
}

.filter-text-input,
.input-year-min,
.input-year-max {
    padding: 8px;
    border: 1px solid #d4d3d3;
    border-radius: 4px;
}

.year-input {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.year-field input {
    width: 80px;
}

.separator {
    font-weight: bold;
}

.slider {
    height: 5px;
    position: relative;
    background: #d4d3d3;
    border-radius: 5px;
}

.slider .progress {
    height: 100%;
    left: 25%;
    right: 25%;
    position: absolute;
    border-radius: 5px;
    background: #c0101f;
}

.range-container {
    position: relative;
}

.range-container input {
    position: absolute;
    width: 100%;
    height: 5px;
    top: -6px;
    background: none;
    pointer-events: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

.year-range-min {
    left: -5px;
}

.year-range-max {
    right: -8px;
}

#draft-status-input-container {
    display: flex;
    flex-direction: row;
    column-gap: 8px;
}

#draft-status-input-container label {
    margin: 0;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    pointer-events: auto;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    background: #c0101f;
    cursor: pointer;
    box-shadow: 0 0 6px rgba(0, 0, 0, 0.05);
}

input[type="range"]::-moz-range-thumb {
    height: 17px;
    width: 17px;
    border: none;
    border-radius: 50%;
    background: #17a2b8;
    pointer-events: auto;
    -moz-appearance: none;
    box-shadow: 0 0 6px rgba(0, 0, 0, 0.05);
}

.filter-button {
    padding: 10px 20px;
    background-color: #c0101f;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-right: 10px;
    transition: background-color 0.1s ease-in-out;
}

.filter-button:hover {
    background-color: #a00c1a;
}

/* Styles for Woman Detail Page */
.profile-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.profile-header {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 20px;
    padding: 20px 0;
    border-bottom: 2px solid #e0e0e0;
    margin-bottom: 30px;
}

.woman-profile-picture {
    max-width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #ddd;
}

.profile-header-name {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.profile-name {
    font-size: 2.2em;
    margin: 0;
    color: #333;
    font-weight: 600;
}

.profile-header-name p {
    margin: 0;
    color: #666;
    font-size: 1.1em;
    margin-top: -5px;
}

.profile-name .draft-tag {
    color: #666;
    font-style: italic;
    font-size: 20px;
    margin-top: 3px;
}

.profile-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.profile-left, .profile-right {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.profile-vitals,
.profile-alternate-names,
.profile-family,
.profile-biography,
.profile-events,
.profile-record-links,
.profile-researchers {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.profile-section-heading {
    font-size: 1.3em;
    font-weight: 600;
    color: #c0101f;
    margin: 0 0 15px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #c0101f;
}

.profile-label {
    font-weight: 600;
    color: #444;
    margin: 0 0 5px 0;
    font-size: 0.95em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.family-children .children-grid,
.family-marriage .marriage-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 10px;
}

.child-container,
.marriage-container {
    background: #f9f9f9;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.child-container p, 
.marriage-container p {
    margin: 0;
    font-size: 14px;
}

.profile-vitals p:not(.profile-section-heading):not(.profile-label),
.profile-alternate-names p:not(.profile-section-heading):not(.profile-label),
.profile-family p:not(.profile-section-heading):not(.profile-label),
.profile-events p:not(.profile-section-heading):not(.profile-label),
.profile-record-links p:not(.profile-section-heading):not(.profile-label),
.profile-researchers p:not(.profile-section-heading):not(.profile-label) {
    margin: 0 0 2px 0;
    color: #555;
}

.profile-vitals .profile-label:not(:first-child),
.profile-alternate-names .profile-label:not(:first-child),
.profile-family .profile-label:not(:first-child),
.profile-events .profile-label:not(:first-child) {
    margin-top: 15px;
}

.vitals-birth,
.vitals-death,
.first-names-section,
.family-marriage,
.family-children {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid grey;
}

.vitals-burial,
.last-names-section,
.family-parents {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.intermediary-label {
    font-weight: bold;
}

.profile-biography p {
    line-height: 1.6;
    color: #444;
}

.profile-record-links a,
.profile-family a,
.profile-events a,
.faculty-container a,
.about-body a,
.profile-researchers a {
    color: #d31a29;
    text-decoration: none;
    font-weight: 500;
}

.profile-record-links a:hover,
.profile-family a:hover,
.profile-events a:hover,
.faculty-container a:hover,
.about-body a:hover,
.profile-researchers a:hover {
    text-decoration: underline;
    color: #a5131f;
}

.profile-footer {
    text-align: center;
    padding: 20px 0;
    border-top: 2px solid #e0e0e0;
}

.profile-footer a,
.explore-button {
    background: #c0101f;
    color: white;
    padding: 12px 24px;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.profile-footer a:hover,
.explore-button:hover {
    background: #aa0e1b;
    text-decoration: none;
}

@media (max-width: 768px) {
    .profile-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .profile-header {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .profile-biography {
        grid-column: 1;
    }
}

/* Styles for the About Page */
.about-page {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
}

.about-page h3 {
    margin-top: 0;
    margin-bottom: 15px;
    color: #c0101f;
    font-size: 1.3em;
    border-bottom: 2px solid #c0101f;
    padding-bottom: 8px;
}

.about-header,
.about-body {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.about-header {
    display: flex;
    flex-direction: column;
}

.about-header p {
    border-bottom: 1px solid rgb(163, 160, 160);
    padding-bottom: 15px;
}

.explore-button {
    margin: auto;
    text-decoration: none;
}

.about-body {
    display: flex;
    flex-direction: column;
}

.about-body-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.body-researchers,
.body-developers,
.body-alumni,
.body-faculty {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.researcher-container,
.faculty-container {
    display: flex;
    flex-direction: column;
    gap: 1px;
    background: #f9f9f9;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    padding: 12px;
    max-width: 250px;
}

.researcher-name,
.faculty-name {
    font-weight: bold;
    margin-bottom: 5px;
    margin-top: 0;
    color: #444;
}

.researcher-time,
.faculty-role {
    color: #555;
    font-size: 0.9em;
    margin: 0;
}

@media (max-width: 1200px) {
    .about-body-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .about-body-content {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

/* Styles for the Contact Us Page */
.contact-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.contact-header {
    padding: 40px 20px 40px 20px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.contact-header a {
    color: #d31a29;
    text-decoration: none;
    font-weight: 500;
}

.contact-header a:hover {
    text-decoration: underline;
    color: #a5131f;
}

.contact-form {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    padding: 20px;
    gap: 10px;
}

.contact-form label {
    font-weight: bold;
    color: #444;
    margin-bottom: 5px;
    font-size: 20px;
    text-transform: uppercase;
    display: block;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
    padding: 10px 12px;
    border: 1px solid #d4d3d3;
    border-radius: 4px;
    font-size: 14px;
    color: #555;
    box-sizing: border-box;
}

.contact-form textarea {
    width: 100%;
    resize: none;
}

.contact-form img {
    display: block;
    max-width: 150px;
    min-width: 100px;
    width: 10%;
    margin-bottom: 5px;
}

.submit-contact-form {
    width: auto;
    padding: 12px 30px;
    background-color: #c0101f;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    font-size: 16px;
    transition: background-color 0.3s ease-in-out;
    align-self: flex-start;
}

.submit-contact-form:hover {
    background-color: #aa0e1b;
}

.contact-form .errorlist {
    list-style: none;
    padding: 0;
    margin: 5px 0 0 0;
    color: #c0101f;
    font-size: 0.9em;
}

/* Styles for Profession Detail and Researcher Detail Pages */
.profession-container,
.researcher-detail-container {
    margin: 10px 40px 30px 40px;
    display: flex;
    flex-direction: column;
}

.profession-header,
.researcher-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-left: 12.5%;
    margin-bottom: 15px;
}

.profession-container .pagination,
.researcher-detail-container .pagination {
    margin-right: 15%;
    font-size: 20px;
}

.profession-container .women-table,
.researcher-detail-container .women-table {
    width: 75%;
    margin: auto;
}

.profession-container .women-table-cell,
.researcher-detail-container .women-table-cell {
    font-size: 20px;
}

.profession-container .women-table-header,
.researcher-detail-container .women-table-header {
    grid-template-columns: 1fr 1fr 1fr;
    font-size: 30px;
}

.profession-container .women-table-row,
.researcher-detail-container .women-table-row {
    grid-template-columns: 1fr 1fr 1fr;
}

.profession-footer .pagination,
.researcher-footer .pagination {
    margin-top: 15px;
    margin-right: 13%;
    float: right;
}

/* Styles for Countries of Origin and Utah Communities Pages */
.country-item a,
.county-item a {
    color: #d31a29;
    text-decoration: none;
    font-weight: bolder;
}

.country-item a:hover,
.county-item a:hover {
    text-decoration: underline;
    color: #a5131f;
}

/* Styles for Country Detail and County Detail Pages */
.country-detail-container,
.county-detail-container {
    display: flex;
    flex-direction: column;
}

.country-detail-content,
.county-detail-content {
    background: #fff;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    border: 1px solid #e5e5e5;
    border-radius: 5px;
    gap: 20px;
    padding: 15px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.detail-label {
    font-size: 1.3em;
    font-weight: 600;
    color: #c0101f;
    margin: 0 0 15px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #c0101f;
}

.person-grid,
.county-person-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 15px;
}

.country-person,
.county-person {
    background: #f9f9f9;
    padding: 12px;
    border: 1px solid #e5e5e5;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.country-person p,
.county-person p {
    margin: 0;
}

.country-person a,
.county-person a {
    color: #d31a29;
    text-decoration: none;
    font-weight: 500;
}

.country-person a:hover,
.county-person a:hover {
    text-decoration: underline;
    color: #a5131f;
}