body {
    font-family: Arial, sans-serif;
}

body, html {
            margin: 0;
            padding: 0;
            height: 100%;
            display: flex;
            flex-direction: column;
        }

#map {
    width: 100%;
    top: 50px;
    position: fixed;
    height: calc(100vh - 50px); /* 100vh minus the height of the header */
    flex-grow: 1
    margin: 0;
    padding: 0;
}

/* Style for the top navigation bar */
.top-bar {
    display: flex;
    justify-content: flex-end;  /* Center the content horizontally */
    align-items: center;      /* Align items vertically */
    height: 50px;
    background-color: #f1f1f1;
    position: relative;
}

#dropdown-title {
    position: absolute;
    top: 5px;
    left: 50%;
    transform: translatex(-50%);
    background-color: white;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    padding: 10px 40px;  /* adjust padding for proper spacing */
    min-width: 300px;
    z-index: 1000;
    display: flex;  /* use flexbox for alignment */
    justify-content: center;  /* center the text horizontally */
    align-items: center;  /* center the content vertically */
    text-transform:capitalize;
}

.fas.fa-chevron-down {
    position: absolute;
    right: 15px;  /* Fixed position from the right of the container */
    font-size: 12px;
    color: black;
}

    /* Style the login/logout links */
    .dropdown-option {
        text-decoration: none;
        font-size: 16px;
        color: #007bff;
        padding: 8px 16px;
        border-radius: 4px;
    }

    .dropdown-option:hover {
        background-color: #e2e6ea;
        color: #0056b3;
    }


.dropdown-content {
        align-items: center;
        gap: 10px;
        margin-right: 10px;
        position: relative; /* Ensure the dropdown is positioned relative to the user icon */
    }

.show-dropdown {
    display: block;
}


/* Style for the select */
#data-select {
    padding: 8px;
    border: none;
    background-color: #fff;
    cursor: pointer;
}

.hamburger-menu {
    font-size:18px;
    cursor: pointer;
}

.subscribe-button {
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    margin-top: 10px;
}

.subscribe-button:hover {
    background-color: #0056b3;
}

.legal-info-link {
    text-align: center;
}

.legal-info-link a {
    color: #007bff;
    text-decoration: none;
}

.legal-info-link a:hover {
    text-decoration: underline;
}


    /* Style the user menu */
    .user-menu {
        display: flex;
        align-items: center;
        gap: 10px;
        margin-right: 10px;
    }

    .user-icon-wrapper {
      position: relative;
      display: inline-block;
    }

    /* Style the user icon */
    .user-icon {
        width: 40px;
        height: 40px;
        border-radius: 50%;
        object-fit: cover;
        border: 2px solid #ccc;
        cursor: pointer;
    }

@keyframes spin-in {
  0% {
    transform: scale(0) rotate(1000deg);
    opacity: 1;
  }
  50% {
    transform: scale(1);
    opacity: 1;
  }
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
}

.badge {
  animation: spin-in 3s ease-out;
  position: absolute;
  top: 0px;
  right: -2px;
  background-color: gold;
  color: white;
  font-weight: bold;
  padding: 2px 4px;
  border-radius: 50px;
  font-size: 8px;
  box-shadow: 1px 2px 2px rgba(0, 0, 0, 0.2);
  transform: rotate(0deg); /* Create the angled effect */
  text-transform: uppercase;
  text-shadow: 0px 0.5px 2px rgba(0, 0, 0, 0.2); /* Dark shadow for better readability */
}


   /* Style the username */
    #user-name {
        font-size: 16px;
        font-weight: 500;
        color: #333;
        cursor: pointer;
    }

    .title-dropdown {
        position: absolute;
        top: 52px;
        transform: translateX(-50%);
        left: 50%;
        background-color: white;
        box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
        border-radius: 8px;
        min-width: 300;
        padding: 10px 80px 10px 80px;
        z-index: 1000;
        display: none;
    }

    /* Style the login/logout links */
    .title-link {
        display: block;
        text-decoration: none;
        font-size: 16px;
        color: #007bff;
        padding: 12px 10px;
        border-radius: 4px;
        min-width: 200px;
    }

    .title-link:hover {
        background-color: #e2e6ea;
        color: #0056b3;
    }




 /* Dropdown styling */
    .user-dropdown {
        position: absolute;
        top: 52px;
        right: 0;
        background-color: white;
        box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
        border-radius: 8px;
        padding: 10px;
        z-index: 1000;
        display: none;
    }

    /* Style the login/logout links */
    .menu-link {
        display: block;
        text-decoration: none;
        font-size: 16px;
        color: #007bff;
        padding: 12px 10px;
        border-radius: 4px;
    }

    .menu-link:hover {
        background-color: #e2e6ea;
        color: #0056b3;
    }


.customize-map-btn {
    padding: 10px 20px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.customize-map-btn:hover {
    background-color: #0056b3;
}

#entity-input-1, #entity-input-2 {
    width: calc(100% - 20px);
    padding: 10px;
    margin: 10px 0;
}

/* Entity Prompt Styling */
.entity-prompt {
    font-size: 14px;
    color: #777;
    margin-top: 5px;
    margin-bottom: 10px;
    text-align: center;
}

.per-capita-link {
    color: #007bff;
    text-decoration: none;
    cursor: pointer;
    font-weight: bold;
}

.per-capita-link:hover {
    text-decoration: underline;
}


.typing-suggestions-wrapper {
    font-size: 16px;
    margin-bottom: 20px; /* Increase space below typing text */
    white-space: nowrap;
    overflow: hidden;
}

.generate-map-btn {
    margin-top: 10px;
    padding: 10px 20px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    width: 100%;
    font-size: 16px;
}

.generate-map-btn:hover {
    background-color: #0056b3;
}


#generate-map {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
}

    .modal-title {
        font-size: 18px;
        color: #333;
        font-weight: bold;
        text-align: center;
        font-style: italic;
    }

    .modal {
        display: none;
        position: fixed;
        z-index: 1000;
        left: 0;
        top: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
        justify-content: center;
        align-items: center;
    }

    .modal-content {
        background-color: white;
        padding: 20px;
        border-radius: 8px;
        max-width: 400px;
        width: 100%;
        position: relative;
        max-height: 90%;
        overflow-y: auto;
    }

    .modal-content h2, h3{
        margin-top: 0;
    }

    #subscription-modal .modal-content {
        width: 600px;
        max-width: calc(100% - 100px);
    }

    .close-button {
        position: absolute;
        top: 10px;
        right: 10px;
        cursor: pointer;
    }

    .modal-content.textarea {
        width: 100%;
        min-height: 100px;
    }


 label {
        display: block;
        margin-top: 10px;
    }

    input {
        width: calc(100% - 16px);
        padding: 8px;
        margin-top: 5px;
        margin-bottom: 10px;
        border: 1px solid #ccc;
        border-radius: 4px;
    }

    textarea {
        width: calc(100% - 16px);
        padding: 8px;
        margin-top: 5px;
        margin-bottom: 10px;
        border: 1px solid #ccc;
        border-radius: 4px;
    }


/* General styling for the feature request container */
.feature-request-container {
    display: flex;
    align-items: flex-start;  /* Align the icon to the top of the request */
    margin-bottom: 20px;
    background-color: #f9f9f9;  /* Background color for the container */
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    max-width: 600px;  /* Optional: Limit the width of the container */
}

/* Styling for the user info section */
.fr-user-info {
    margin-right: 15px;  /* Space between user info and the feature request */
    text-align: center;  /* Center the username above the icon */
    width: 80px;  /* Fixed width for the user info section */
}

/* Style for the user icon */
.fr-user-icon {
    width: 60px;  /* Set a fixed size for the icon */
    height: 60px;
    border-radius: 50%;  /* Make the icon circular */
    margin-bottom: 5px;  /* Space between the icon and the name */
    object-fit: cover;   /* Ensure the image fits within the circle */
}

/* Style for the user name */
.fr-user-name {
    display: block;
    font-weight: bold;
    font-size: 14px;
    color: #333;
    text-align: center;  /* Ensure the name is centered */
}

/* Style for the feature request content */
.feature-request {
    flex: 1;  /* Let the feature request take up the remaining space */
    padding: 0px 0px 0px 10px;
}

.feature-request p {
    margin: 0;
    font-size: 16px;
    color: #444;
}

.feature-request small {
    padding: 5px 0px 0px 0px;
    color: #777;
    display: block;
}


/* Styles specific to the subscription modal */
#subscription-modal .modal-content {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    max-width: 600px;
    width: 100%;
    position: relative;
    max-height: 90%;
    overflow-y: auto;
    box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.1);
}

#subscription-modal .close-button {
    position: absolute;
    top: 10px;
    right: 10px;
    cursor: pointer;
    font-size: 24px;
    color: #444;
    transition: color 0.2s;
}

#subscription-modal .close-button:hover {
    color: #f44336;
}

#subscription-modal .modal-content h2 {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin: 0;
    padding: 10px 0;
    text-align: center;
    border-bottom: 2px solid #f0f0f0;
}

#subscription-modal .modal-content h3 {
    font-size: 20px;
    font-weight: 500;
    color: #666;
    margin: 10px 0;
    text-align: center;
}

#subscription-modal .pricing-tiers {
    display: flex;
    flex-direction: row;  /* Arrange tiers side-by-side */
    gap: 20px;  /* Space between tiers */
    margin-top: 20px;
    justify-content: center;  /* Center the tiers horizontally */
    flex-wrap: wrap;  /* Allow wrapping on smaller screens */
}

#subscription-modal .tier {
    flex: 1;
    min-width: 200px;  /* Minimum width to ensure tiers are responsive */
    max-width: 280px;  /* Maximum width to keep tiers balanced */
    padding: 20px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background-color: #f9f9f9;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s, box-shadow 0.2s;
}

#subscription-modal .tier:hover {
    transform: translateY(-4px);
    box-shadow: 0px 6px 12px rgba(0, 0, 0, 0.1);
}

#subscription-modal .tier h3 {
    font-size: 22px;
    font-weight: 600;
    color: #333;
    margin: 0 0 10px;
    text-align: center;
}

#subscription-modal .tier p {
    font-size: 18px;
    font-weight: 500;
    color: #444;
    margin: 0 0 15px;
    text-align: center;
}

#subscription-modal .tier ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

#subscription-modal .tier ul li {
    display: flex;
    align-items: center;
    font-size: 16px;
    color: #555;
    margin: 8px 0;
    padding-left: 24px;
    position: relative;
}

#subscription-modal .tier ul li::before {
    content: "✔";
    position: absolute;
    left: 0;
    font-size: 16px;
    color: #4CAF50;
    font-weight: bold;
}

#subscription-modal .subscribe-button {
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    margin-top: 15px;
}

#subscription-modal .subscribe-button:hover {
    background-color: #0056b3;
}

#subscription-modal .subscribe-button:active {
    background-color: #003f7f;
}

/* Horizontal line to separate subscription status */
.subscription-divider {
    border: none;
    border-top: 1px solid #ccc;
    margin: 10px 0;
}

#subscription-modal .subscription-status {
    font-size: 12px;
    color: #333;
    text-align: left; /* Explicitly set left alignment */
    margin-top: 4px;
}

#subscription-modal .subscription-status p {
    margin: 2px 0;
    line-height: 1.2;
    text-align: left; /* Ensure each paragraph is aligned left */
    font-size: 14px;
}

#subscription-modal .subscription-status p strong {
    font-weight: 600;
    color: #444;
}

#subscription-modal .subscription-status span {
    color: #007bff;
    font-weight: 500;
    text-align: left; /* Ensure spans are aligned left */
}

#subscription-modal #subscription-status {
    font-weight: bold;
    color: #4CAF50; /* Adjust color based on status */
}

.mapboxgl-popup {
    z-index: 100 !important;  /* Ensures popup is above all other elements */
}

.mapboxgl-popup-content {
    overflow-y: auto;      /* Enable vertical scrolling when content exceeds height */
    max-height:400px;
    padding: 10px;         /* Add some padding inside the popup */
    box-sizing: border-box; /* Ensure padding is included in width/height calculations */
}

.popup-image {
    border-radius: 5px;
}

.popup-text {
    flex-grow: 1;
    word-wrap: break-word;
}

.popup hr {
    margin: 10px 0;
}

.mapboxgl-ctrl-geocoder, .mapboxgl-ctrl-geocoder .suggestions {
      box-shadow: 0px 0px 3px 1px rgba(0, 0, 0, 0.3) !important; /* Match shadow */
}

.mapboxgl-ctrl-group {
      box-shadow: 0px 0px 3px 1px rgba(0, 0, 0, 0.3) !important; /* Match shadow */
}

.mapboxgl-ctrl-group button {
    width: 36px !important;
    height: 36px !important;
}

.mapboxgl-ctrl-geocoder--icon-close {
    margin-top: 3px !important;
    width: 16px !important;
    height: 16px !important;
}

.mapboxgl-ctrl-geocoder--icon-search {
    top: 8px !important;
    left: 8px !important;
    width: 20px !important;
    height: 20px !important;
}

.mapboxgl-ctrl-geocoder--input {
    height: 36px !important; /* Forces height override */
    padding: 6px 35px !important;
}

.mapboxgl-ctrl-geocoder.mapboxgl-ctrl-geocoder--collapsed {
    min-width: 36px !important;
    width: 36px !important;
}

.mapboxgl-ctrl-geocoder {
    z-index: 10 !important; /* Adjust Geocoder's z-index */
}

.custom-toast {
    color: black !important;
    background: white !important;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2) !important;
    border-radius: 8px !important;
}


/* Basic Modal Styling */
/* Modal Content Styling */
#advanced-config-modal .modal-content {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    max-width: 500px;
    width: 100%;
    position: relative;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2);
}

/* Section Styling */
.section {
    margin-bottom: 20px;
}

.section h3 {
    font-size: 1.1em;
    margin-bottom: 10px;
}

/* Colormap and Background Icon Grids */
.colormap-grid, .background-grid, .marker-display {
    display: flex;
    gap: 10px;
    justify-content: space-around;
    margin-top: 10px;
    flex-wrap: wrap; /* Allows items to wrap if needed */
}
.colormap-grid::after, .background-grid::after, .marker-grid::after {
  content: "";
  flex: auto;
}


/* Icon Container for Colormaps, Backgrounds, and Marker Options */
.colormap-icon, .background-option, .marker-option {
    width: 80px; /* Fixed width for consistent alignment */
    text-align: center;
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: transform 0.2s, border 0.2s;
}

/* Image Styling for Icons */
.colormap-icon img, .marker-option img {
    width: 60px; /* Set icon width */
    height: 60px; /* Set icon height for consistency */
    border-radius: 4px;
    margin-bottom: 5px; /* Space between icon and label */
}

/* Background Option Styling */
.background-option {
    width: 80px;
    text-align: center;
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: transform 0.2s, border 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center; /* Center-aligns children */
}

/* Centered and Cropped Background Image */
.background-preview {
    width: 60px;            /* Set desired icon size */
    height: 60px;
    border-radius: 4px;
    margin: 0 auto 5px auto; /* Center the div horizontally and add space below */
    background-size: 300%;   /* Zoom in slightly to crop the edges */
    background-position: center; /* Center the image within the div */
    background-repeat: no-repeat;
}


/* Label Styling for Consistent Icon Width */
.colormap-icon span, .background-option span, .marker-option span {
    display: block;
    font-size: 0.9em;
    text-align: center;
    white-space: nowrap; /* Prevents text wrapping */
    overflow: hidden; /* Ensures text doesn’t overflow */
    text-overflow: ellipsis; /* Adds ellipsis for longer text */
}

.colormap-icon, .background-option, .marker-option {
//    border: 2px solid #FFFFFF; /* Highlight border on hover or selection */
}

/* Hover and Selection Effects */
.colormap-icon:hover, .background-option:hover, .marker-option:hover,
.colormap-icon.selected, .background-option.selected, .marker-option.selected {
    transform: scale(1.05);
    border: 2px solid #007BFF; /* Highlight border on hover or selection */
}

/* Toggle Switch Styling */
.toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.toggle-switch {
    width: 40px;
    height: 20px;
    background: #ccc;
    border-radius: 10px;
    position: relative;
    -webkit-appearance: none;
    outline: none;
    cursor: pointer;
    transition: background-color 0.2s;
}

.toggle-switch:checked {
    background-color: #007BFF;
}

.toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: white;
    transition: transform 0.2s;
}

.toggle-switch:checked::after {
    transform: translateX(20px);
}

/* Slider Styling */
.slider-value {
    text-align: center;
    font-size: 1.1em;
    margin-top: 5px;
}

.apply-button {
    width: 100%;
    padding: 10px;
    background-color: #007BFF;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1.1em;
    transition: background-color 0.2s;
}

.apply-button:hover {
    background-color: #0056b3;
}


/* Icon styling within the button */
#open-styling-modal-btn .map-styling-icon {
    width: 20px;
    height: 20px;
    display: inline-block;
    vertical-align: middle;
}

/* Map Styling Control Button */
#open-styling-modal-btn {
    width: 36px;
    height: 36px;
    border-radius: 5px;
    background-color: #FFFFFF; /* Mapbox-like color */
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0px 0px 3px 1px rgba(0, 0, 0, 0.3) !important; /* Match shadow */
    position: relative;
    transition: background-color 0.3s;
    outline: none;
}

/* Hover Effect */
#open-styling-modal-btn:hover {
    background-color: #F2F2F2;
}

/* Pulse Animation */
#open-styling-modal-btn.pulse {
    animation: pulse 1.5s infinite;
}

/* Define Pulse Animation */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(0, 123, 255, 0.4);
    }
    50% {
        transform: scale(1.1);
        box-shadow: 0 0 0 10px rgba(0, 123, 255, 0);
    }
}


/* For mobile responsiveness */
@media (max-width: 800px) {
    #dropdown-title {
        min-width: 200px;  /* Adjust padding for proper spacing */
    }
    .title-dropdown {
        min-width: 200px;  /* Adjust padding for proper spacing */
        padding: 10px 30px 10px 30px;
    }
}
@media (max-width: 600px) {
    #subscription-modal .modal-content {
        width: 400px;
        max-width: calc(100% - 100px);
    }
    .pricing .pricing-tiers {
        display: block;
        width: 100%;
    }

    .pricing .tier {
        width: calc(100% - 30px);
    }



    #dropdown-title {
        padding: 10px 40px 10px 10px;  /* Adjust padding for proper spacing */
        transform: none;
        left: 10px;
    }
    .title-dropdown {
        min-width: 200px;  /* Adjust padding for proper spacing */
        padding: 10px 20px 10px 10px;
        transform: none;
        left: 10px;
    }
    .user-icon {
       display: none;
       visibility: none;
    }
}

/* For mobile responsiveness */
@media (max-width: 430px) {
    #dropdown-title {
        min-width:0px;
    }
    .title-dropdown {
       min-width: 0px;
       padding: 10px 20px 10px 10px;
    }
    .title-link {
        min-width: 0px;
    }
    #user-name-wrapper {
       display: none;
    }
    .user-icon {
       display: none;
       visibility: none;
    }
}
