html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

footer {
    background-color: #2f4f4f;
    color: white;
    padding: 20px 0;
    text-align: center;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

html {
    scroll-behavior: smooth;
}

.secondary-navbar {
    background-color: var(--secondary-navbar-bg);
    color: var(--secondary-navbar-text);
    height: auto;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: none !important;
    margin-bottom: 0.5em !important;
}

.secondary-navbar .navbar-nav {
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    justify-content: flex-start;
    gap: 0.4rem;
}

.secondary-navbar .navbar-nav .nav-item {
    flex: 0 1 auto;
}

@media (max-width: 768px) {
    .secondary-navbar .navbar-nav .nav-link {
        white-space: nowrap;
        padding: 0.5rem 0;
    }
}

@media (min-width: 1000px) {
    .secondary-navbar {
        height: 2.5em;
        padding: 0.25rem 1rem;
        margin-bottom: 1em !important;
    }
}

.navbar-nav .nav-item .dropdown-menu {
    z-index: 1050;
}

.dropdown-submenu .dropdown-menu, .dropdown-menu  {
    text-align: center;
}

@media (max-width: 991px) {
    .customNavBar.navbar-nav {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        width: 100%;
    }

    .customNavBar.navbar-nav .nav-item, .customNavBar.navbar-nav .nav-link {
        width: 100%;
    }

    #notification-bubble {
        display: inline-block;
        margin-left: 0.5em;
        width: 15%;
    }
}

.secondary-navbar .nav-link {
    color: var(--secondary-navbar-link);
}

.secondary-navbar .nav-link:hover {
    color: var(--secondary-navbar-link-hover);
}

#site-description, #featured-case, #newest-cases, #highlighted-cases, #newest-articles {
    scroll-margin-top: 1.3em;
}

#timeline {
    scroll-margin-top: 1em;
}

@media (max-width: 576px) { 
    #site-description, #featured-case, #newest-cases, #highlighted-cases, #newest-articles {
        scroll-margin-top: 1em;
    }

    #timeline {
        scroll-margin-top: 0.9em;
    }
}

@media (max-width: 992px) {
    .secondary-navbar {
        padding-top: 0.5rem;
        padding-bottom: 0.5rem;
        position: static !important;
    }

    .navbar-nav .nav-item {
        padding-right: 1rem;
    }
}

@media (max-width: 576px) {
    .secondary-navbar {
        font-size: 0.9rem;
    }

    .navbar-nav .nav-item {
        margin-bottom: 0.5rem;
    }
}

footer div {    
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.no-underline {
    text-decoration: none;
    color: #ffc107;
    font-weight: bold;
}

.no-underline:hover {
    color: #ff9800;
    background-color: rgba(255, 255, 255, 0.2);
    padding: 2px;
    border-radius: 4px;
}

.navbar {
    background-color: #333333;
}

.navbar-nav .nav-link {
    color: #ffffff;
}

.navbar-nav .nav-link:hover {
    color: #d1d1d1;
}

.navbar-toggler {
    border-color: #ffffff;
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30' viewBox='0 0 30 30'%3E%3Cpath stroke='rgba(255, 255, 255, 1)' stroke-width='2' d='M5 7h20M5 15h20M5 23h20'/%3E%3C/svg%3E");
}

.navbar-toggler {
    padding: 0.5rem 1rem;
    font-size: 1.25rem;
}

.navbar .navbar-nav .nav-link.active {
    color: #ff9800;
}

.navbar-brand {
    color: #ffffff;
}

a.navbar-brand:hover,
a.navbar-brand:active {
    color: #33ff99;
}

.navbar ul li.nav-item {
    font-size: 1.1em;
}

.person-details {
    border: 2px solid #d3d3d3;
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
}

@media (max-width: 767px) {
    .person-details {
        border: none;
        padding: 0 10px;
        margin-top: 0.5em;
    }
}

.person-description h2 {
    margin-bottom: 10px;
}

.person-description {
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
}

.person-description img,
.timeline-container img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 0.25em;
}

.person-photo {
    width: auto;
    max-width: 100%;
    max-height: 65vh;   
    height: auto;
    object-fit: contain;
    border: 1px solid #d3d3d3;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.img-grayscale {
    filter: grayscale(100%);
    position: relative;
}

.img-greenscale {
    filter: grayscale(70%);
    position: relative;
}

.found-label {
    position: relative;
    background-color: rgba(255, 165, 0, 0.8);
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.9em;
    font-weight: bold;
    max-width: 40vh;
}

.close-btn:hover {
    filter: brightness(1.2);
}

.found-label.alive {
    background-color: rgba(0, 128, 0, 0.7);
}

.form-check.custom-radio {
    position: relative;
    padding-left: 30px;
    margin-bottom: 10px;
}

.custom-radio .form-check-input {
    position: absolute;
    opacity: 0;
}

.custom-radio .form-check-label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    border: 2px solid black;
    border-radius: 50%;
    background-color: white;
}

.custom-radio .form-check-input:checked + .form-check-label::before {
    background-color: #007bff;
}

.custom-radio .form-check-input:checked + .form-check-label::before {
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.3);
}

.custom-radio .form-check-label {
    margin-left: 10px;
    cursor: pointer;
}

#person-map {
    width: 100%;
    height: 80vh;
    border: 1px solid #d3d3d3;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    position: relative;
}

.person-name {
    color: #333; 
    text-decoration: none; 
    font-weight: bold;
}

.person-name i {
    margin-left: 3px;
    font-size: 1em;
    color: #007bff;
}

.timeline-container .card {
    background-color: #f8f9fa;
    border-radius: 12px;
    padding: 5px;
    border: 2px solid #d3d3d3;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.timeline {
    list-style: none;
    padding: 0;
}

.timeline-item {
    position: relative;
    padding: 5px;
    margin-bottom: 20px;
    margin-left: 1em;
}

ul.timeline li.timeline-item .timeline-content {
    background-color: #f9f9d8;
}

.timeline-marker {
    position: absolute;
    left: -20px; /* Adjust position based on design */
    top: 40px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    color: white; /* Icon color */
    display: flex;
    align-items: center;
    justify-content: center;
}

.timeline-content {
    background: #f9f9f9;
    border: 2px solid #d3d3d3;
    border-radius: 5px;
    padding: 1em;
    margin-left: 1em;
    margin-top: 1em;
}

.weather-data {
    background-color: #d1e7ff;
    padding: 10px;
    border-radius: 5px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1em;
    border: 1px solid #adb5bd;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.personCarouselContainer {
    background-color: #f9f9f9;
    border: 2px solid #d3d3d3;
    border-radius: 12px;
    padding: 1em;
    margin-top: 1em;
    margin-bottom: 1em;
}

.custom-checkbox .form-check-input {
    width: 1.5em;
    height: 1.5em;
    border-radius: 0.25em;
    margin-right: 0.5em;
    border: 1px solid #007bff;
    cursor: pointer;
}

.custom-checkbox .form-check-input:checked {
    background-color: #28a745;
    border-color: #28a745;
}

.form-control, .form-select {
    border: 1px solid #ccc;
    border-radius: 4px;
}

.custom-checkbox .form-check-input:focus {
    box-shadow: 0 0 0 0.2rem rgba(38, 143, 0, 0.5);
}

.breadcrumb {
    padding: 5px 0;
    padding-left: 4em;
    width: 100%;
    margin: 0;
    font-size: 1.1rem;
}

.person-image {
    max-width: 12rem;
    height: auto;
    width: 100%;    
}

.default-image-container {
    padding-left: 2em;
}

.default-photo {
    max-width: 100%;
    height: auto;
}

@media (max-width: 576px) { /* Small screens (e.g., mobile) */
    .image-container img,
    .archive-image-container img {
        height: 300px;
    }
}
@media (max-width: 768px) {
    .breadcrumb {
        padding-left: 0.5em;
    }

    .image-container,
    .archive-image-container {
        height: 50vh;
    }

    .person-photos {
        margin-top: 0.5em;
    }

    .person-photo {
        margin: 0 auto;
        max-width: 80%;
        max-height: 50vh;
    }

    .person-hero {
        text-align: center;
        padding: 5px 15px;
    }

    .person-container h5 {
        font-size: 1.2em;
    }

    .person-container .bi-eye {
        font-size: 1.3em;
    }

    .person-list .img-container {
        padding-left: 1.8em;
    }

    #search-form .row {
        flex-direction: row;
    }

    .col-md-2, .col-md-10 {
        width: 100%;
    } 

    .person-image {
        max-width: 100%;
        height: auto; /* Maintain aspect ratio */
    }

    .default-photo {
        max-width: 100%; /* Adjust as needed */
        height: auto;
    }

    #person-map {
        width: 100%;
        height: 65vh;
    }

    .timeline-content {
        padding: 0.5em;
    }

    .navbar-brand {
        padding-left: 0.5em;
        max-width: 65%; /* Prevent it from getting too wide */
    }
    
    .primarySearch.searchAnchor {
        padding-left: 0.5em;
        padding-right: 0.2em;
    }
}

.breadcrumb-item a {
    color: #007bff;
    text-decoration: none;
}

.breadcrumb-item.active {
    color: #6c757d;
}

.breadcrumb-item a:hover {
    color: #0056b3;
}

body {
    margin: 0;
}

.navbar {
    margin-bottom: 0;
}

#search-results li {
    cursor: pointer;
    padding: 10px;
    border-bottom: 1px solid #ddd;
}

#search-results li:hover {
    background-color: #eee;
}

.result-item {
    padding: 15px;
    margin-bottom: 10px;
    min-height: 100px;
}

.spacer {
    background-size: cover;
    background-position: center;
    height: 300px;
    margin-bottom: 20px;
}

.news-box {
    background-color: #f9f9f9;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.news-box h2 {
    font-size: 1.5em;
    margin-bottom: 20px;
    color: #333;
}

.news-item h3 {
    font-size: 1.2em;
    margin-bottom: 10px;
    color: #007bff;
}

.news-item p {
    font-size: 0.95em;
}

.news-item a {
    text-decoration: none;
}

.news-item a:hover {
    text-decoration: underline;
}

.news-box .news-item,
.news-list .news-item {
    border: 1px solid #d3d3d3;
    padding-bottom: 10px;
}

.news-box .news-item:last-child {
    border-bottom: none;
}

.modal-body img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

.image-container {
    height: 300px; 
    overflow: hidden;
    position: relative;
}

.archive-image-container { 
    overflow: hidden;
    position: relative;
}

.image-container img,
.archive-image-container img {
    object-fit: cover;
    height: 100%; 
    width: 100%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

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

.avatar {
    width: 50px;      /* Set width to 50 pixels */
    height: 50px;     /* Set height to 50 pixels */
    border-radius: 50%; /* Makes the image round */
}

.news-item {
    transition: box-shadow 0.3s ease; /* Add transition for hover effect */
}

.news-item:hover {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); /* Slight shadow on hover */
}

.summary {
    color: #333; /* Darker text color for summary */
}

.mapboxgl-popup-close-button {
    font-size: 2.0em;
}

#person-map .mapboxgl-popup {
    max-width: 50em;
    width: 30em;
}

.dimmed-text {
    position: relative;
    max-height: 4.5em;
    overflow: hidden;
    color: #6c757d;
}

.dimmed-text:after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    height: 1.5em;
    width: 100%;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 1) 100%);
}

#reset-dates {
    margin-left: 1em;
}

.search-button {
    width: 10em;
}

.dropdown-menu .dropdown-item:hover {
    background-color: #007bff;
    color: white;
}

.dropdown-menu .dropdown-item:focus {
    background-color: #007bff;
    color: white;
}

#scrollToTop, #scrollToDown {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    border: none;
    border-radius: 50%;
    background-color: #007bff;
    color: white;
    padding: 10px;
    font-size: 16px;
    cursor: pointer;
    transition: opacity 0.3s ease;
}

#scrollToTop:hover, #scrollToDown:hover {
    background-color: #0056b3;
}

#styleSwitcher {
    position: absolute;
    top: 0;
    left: 0;
    padding: 5px;
    border-radius: 4px;
    z-index: 9999;
    width: 150px;
}

#styleSwitcher.main-map {
    left: inherit;
    top: 0;
    right: 2.5em;
}

#person-map-container {
    position: relative;
    flex: 0 1 auto;
}

.highlighted-case .short-description .card-text, .new-case .short-description .card-text {
    height: 15vh;
    overflow-y: auto;
}

.person-of-week.short-description .card-text {
    min-height: auto;
    height: auto;
}

.person-name i.icon-large {
    font-size: 1.5rem;
}

@media (max-width: 768px) {
    .highlighted-case .short-description .card-text, .new-case .short-description .card-text {
        height: auto;
        overflow-y: auto;
    }

    .person-name i.icon-large {
        font-size: 2rem;
    }
    
}

.suggestions {
    list-style-type: none;
    padding: 0;
    margin: 0;
    max-height: 200px;
    overflow-y: auto;
    width: 100%;
    border: 1px solid #ccc;
    border-radius: 4px;
    position: absolute;
    background: white;
    z-index: 20000;
}

.suggestions li {
    padding: 8px;
    cursor: pointer;
}

.quick-search-container {
    position: relative;
    width: 100%;
}

.suggestions-base {
    width: 93%;
}

.suggestions:empty {
    visibility: hidden;
}

.suggestions li:hover {
    background-color: #eee;
}

#name-search {
    position: relative;
}

#name-search, #disappearance_location {
    position: relative;
}

.person-list.list-group-item {
    border: 1px solid #d3d3d3;
}

.result-item.card-body.person-container {
    padding-right: 1.5rem;
    padding-bottom: 1.5rem;
    padding-left: 1.5rem;
}

.result-item .lead {
    line-height: 1.5;
}

.result-item .badge {
    border-radius: 0.25rem;
    padding: 0.35rem 0.6rem;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}
.result-item .badge i {
    font-size: 1.1em;
}

.result-item .icon-text {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    margin-right: 1rem;
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.result-item .person-description {
    font-size: 0.95rem;
    padding: 0.5rem;
    border-radius: 0.25rem;
    margin-top: 0.5rem;
}

.result-item .badge-warm-red {
    background-color: #d9534f;
    color: #fff;
    font-weight: 500;
}

.badge-responsive {
    margin-left: 1em;
    width: fit-content;
}

@media (max-width: 575.98px) {
    .badge-responsive {
        font-size: 0.7rem;
        padding: 0.3rem 0.5rem;
        margin-left: 0;
    }
    .badge-responsive i {
        font-size: 0.9rem;
    }
}

@media (max-width: 767px) {
    .pagination .page-link {
        font-size: 1.05rem;
        padding: 0.4rem 0.8rem;
    }
}

#div_id_content {
    width: 100%;
    max-width: 100%;
}

#id_content {
    width: 100% !important;
    max-width: 100% !important;
}

@media (min-width: 768px) {
    #id_content {
        max-width: 600px;
    }
}

.container.userprofile .nav-item .nav-link.active {
    border: 1px solid #007bff;
    border-radius: 0.25rem;
    box-shadow: 0 0 3px rgba(0, 123, 255, 0.4);
    margin-top: -1px;
}

.custom-padding-right {
    padding-right: 1em;
}

.purple-badge {
    background-color: #6f42c1; /* Purple */
    color: white;
    padding: 0.2em 0.6em;
    border-radius: 0.375rem;
    font-size: 0.875em;
}

#footer-links {
    padding: 10px 0;
    text-align: center;
}

#footer-links ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

#footer-links li {
    margin: 0 10px;
}

#footer-links a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

#footer-links a:hover {
    color: #ffc107;
    text-decoration: underline;
}

.donationDiv a {
    text-decoration: none;
}

.donationDiv a:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .persons .col-md-6, 
    .persons .col-lg-6 {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .news-container {
        flex: 0 0 100%;
        max-width: 100%;
        margin-top: 20px;
    }
}

.person-documents a {
    word-wrap: break-word;
    white-space: normal;
}

.social-share-buttons {
    margin-top: 1em;
}

.social-share-buttons a {
    font-size: 0.8rem;
    padding: 0.5rem;
    border-radius: 50%;
    transition: transform 0.3s ease;
}

.social-share-buttons a:hover {
    transform: scale(1.1);
}

.social-share-buttons .btn {
    padding: 0.4rem 0.8rem;
    font-size: 1.0rem;
}

.social-share-buttons .btn i {
    font-size: 1.2rem;
}

.textarea-large {
    height: 200px;
}

@media (max-width: 768px) {
    .textarea-large {
        height: 300px;
    }
}

.mobileDivider {
    border: 0;
    height: 1.5px;
    background-color: #bbb;
    margin: 8px 0;
    opacity: 0.8;
}

#donation-cta {
    background-color: #c8e6c9;
}

#top-donators-footer {
    padding: 10px;
    border-radius: 5px;
}

#top-donators-footer span {
    font-size: 14px;
    font-weight: 500;
    color: #fff;
}

.medal {
    margin-right: 8px;
    font-size: 1.5rem;
}

.gold {
    color: #FFD700;
}

.silver {
    color: #C0C0C0;
}

.bronze {
    color: #CD7F32;
}

.bg-bronze {
    background-color: #cd7f32;
}

#notification-bubble {
    background-color: red;
    color: white;
    font-size: 12px;
    padding: 6px 10px;
    border-radius: 50%;
    text-align: center;
    line-height: 16px;
    min-width: 24px;
    min-height: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    margin-right: 0.5em;
}

@media (max-width: 768px) {
    #notification-bubble {
        right: auto;
        left: 16em;
        top: 0.5em;
    }
}

.person-list.list-group-item.person-highlighted-case {
    background-color: #fffae6;
    border-left: 5px solid #ff9900;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
}

.person-list.list-group-item.person-highlighted-case .person-name h5 {
    font-weight: bold;
    color: #d9534f;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

#notification-bubble, #notification-bubble-mobile {
    animation: pulse 1.5s ease-in-out infinite; /* Slower duration */
}

.notification-item[data-url] {
    cursor: pointer;
    transition: box-shadow 0.2s ease-in-out;
}

.notification-item[data-url]:hover {
    box-shadow: 0 0 8px rgba(255, 140, 0, 0.6), 0 0 15px rgba(255, 140, 0, 0.3);
}

.sticky-notification {
    will-change: top;
    transition: top 0.2s ease-in-out;
}

.list-group-item.archive-extra {
    padding: 0;
    margin: 0;
}

.video-breakout {
    width: 100%;
}

@media (max-width: 576px) {
    .video-breakout {
        --side-gap: 24px;

        width: calc(100vw - (var(--side-gap) * 2));
        margin-left: calc(-50vw + var(--side-gap));
        margin-right: calc(-50vw + var(--side-gap));

        position: relative;
        left: 50%;
        right: 50%;
    }
}

.badge-purple {
    background-color: #6f42c1;
    color: #fff;
}