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

#main {
    border: 1px dotted black;
    display: flex;
    align-items: center;
}

#map {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 100%;
    z-index: 100;
}

#geolocate-button {
    display: none;
}

.btn-br2 {
    border-radius: 2px;
}

.sidebar-bg {
    position: absolute;
    height: 100%;
    width: 39%;
    top: 0;
    right: 0;
    z-index: 410;
    background-color: rgba(255, 255, 255, 0.975);
    overflow-y: auto;
}

.sidebar {
    position: relative;
    top: 0;
    right: 0;
    margin: 0;
    padding: 10px;
    z-index: 430;
    background-color: rgba(255, 255, 255);
    opacity: 1;
    height: 100%;
}

#sidebar-content {
    position: relative;
    top: 0;
    right: 0;
    z-index: 420;
    margin: 0;
    padding: 0;
    background-color: rgba(255, 255, 255);
    opacity: 1;
    height: auto;
}

.tabs {
    display: flex;
}

.tab {
    display: none;
}

.tab.active {
    display: block;
}

.tab-content {
    display: none;
}

.tabs {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.tabs button {
    margin-right: 5px;
}

#toggleSidebarX {
    margin-left: auto;
}


#hamburger-menu {
    display: none;
    position: absolute;
    top: 20px;
    right: 10px;
    z-index: 500;
}

.button-container {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.btn-sidebar {
    border-radius: 2px;
    font-weight: bold;
    margin-inline: 2px;
    float: left;
}

.btn-sidebar-content {
    border-radius: 2px;
    font-weight: bold;
    margin-inline: 2px;
    border-width: 1px;
    border-color: #4e4e4e;
}

.btn-sidebar-content.active {
    border-radius: 2px;
    font-weight: bold;
    margin-inline: 2px;
    background-color: #114511;
    color: #ffffff;
    border-width: 1px;
    border-color: #444;
}

.btn-sidebar-content:hover {
    color: #ffffff;
    background-color: #82b482;
}

.btn-sidebar-content-send  {
    border-radius: 2px;
    font-weight: bold;
    margin-inline: 2px;
    border-width: 1px;
    border-color: #444;
    color: #fff;
    background-color: #0f13f7;
}

.btn-sidebar-content-send:hover {
    color: #ffffff;
    background-color: #00028b;
}

.btn-sidebar-ctrl {
    border-radius: 2px;
    font-weight: bold;
    margin-inline: 2px;
    float: right;
}

#userLogout:hover {
    background-color: rgb(255, 86, 86);
}

.deactivated {
    pointer-events: none;
}

.sidebarControlButtons {
    position: absolute;
    margin-top: 2.75rem;
    padding-bottom: 0;
    padding-right: 1rem;
    right: 0;
    left: auto;
    z-index: 200;
}

.navibar {
    position: absolute;
    top: 0px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.90);
    padding: 10px 25px 10px 25px;
    z-index: 150;
    border-radius: 0px 0px 5px 5px;
}

#navibarAdditionalOptions {
    width: inherit;
    position: relative;
}

.navibarButton {
    padding: 10px;
    border: 1px solid #2f2fff;
    cursor: pointer;
    z-index: 175;
    opacity: 1;
    background-color: white;
    color: inherit;
}

.navibarButton.active {
    background: rgb(0, 75, 0);
    padding: 10px;
    color: white;
    opacity: 1;
}

.navibarButton:hover {
    background-color: #82b482;
    padding: 10px;
    color: white;
    opacity: 1;
}

.accordion {
    background-color: #eee;
    color: #444;
    cursor: pointer;
    padding: 18px;
    width: 100%;
    text-align: left;
    border: none;
    outline: none;
    transition: 0.4s;
}

.active, .accordion:hover {
    background-color: #ccc;
}

.panel {
    padding: 0 18px;
    background-color: white;
    display: none;
    overflow: hidden;
}

.accordion:after {
    content: "\2795";
    font-size: 13px;
    color: #777;
    float: right;
    margin-left: 5px;
}

.accordion.active:after {
    content: "\2796";
}

.input-container {
    display: flex;
    position: relative;
    width: 100%;
}

.autocomplete-input {
    flex-grow: 1;
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    z-index: 999;
}

.autocomplete-input#autocomplete-location {
    width: 90%;
    margin-right: 0;
    border-radius:  4px 4px 4px 4px;
}

.bubbles-container {
    margin-top: 10px;
}

.bubble {
    display: inline-block;
    background-color: #006eff;
    color: white;
    padding: 5px 10px;
    border-radius: 15px;
    margin: 5px;
    cursor: pointer;
}

.bubble:hover {
    background-color: #0053be;
}

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

.autocomplete-list li {
    padding: 10px;
    cursor: pointer;
}

.autocomplete-list li:hover {
    background-color: #f1f1f1;
}

/* Highlighted suggestion */
.autocomplete-list li.highlighted {
    background-color: #007bff;
    color: white;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.data-table th,
.data-table td {
    border: 1px solid #ccc;
    padding: 10px;
    text-align: left;
}

.data-table th {
    background-color: #f2f2f2;
}

.left-col {
    width: 40%; /* Desktop width for left column */
}

.mid-col {
    color: #444444;
    width: 30%;
}

.right-col {
    width: 60%; /* Desktop width for right column */
}

/* Container to handle overflow on mobile */
.table-container {
    width: 100%;
    overflow-x: auto;  /* Allows horizontal scrolling on mobile */
    -webkit-overflow-scrolling: touch;  /* Smooth scrolling on mobile */
}

.lmarker {
    position: absolute;
    transition: opacity 5s ease;
}

.lmarker-inner {
    background-color: blue;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    opacity: 1;
    transition: opacity 5s ease;
}

.lmarker-outter {
    background-color: blue;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    opacity: 0.5;
    transition: opacity 5s ease;
}

.lmarker-border {
    border: 6px solid white;
    width: 54px;
    height: 54px;
    border-radius: 50%;
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 5s ease;
}

.loading-icon {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 10px;
    border-radius: 5px;
    font-size: 12px;
    display: none;
    z-index: 1000;
}

.loading-icon svg {
    animation: spin 1s linear infinite;
    font-size: 24px;
}

#toggleSidebarMobile {
    display: none;
}

.login-div {
    position: absolute;
    padding: 24px;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 3px;
    border-width: 7px;
    border-color: #1919a8;
    border-style: solid;
}

#login-box {
    position: relative;
    max-width: 95%;
}

#logout-button {
    position: relative;
    color: white;
    background-color: darkred;
    pointer-events: auto;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.form-check {
    display: block !important;
}

.form-switch {
    display: block !important;
}

.form-check-input {
    display: inline-block !important;
}

/* Im Aufbau */
.aufbau-tooltip-wrapper {
    position: relative;
    display: inline-block;
}

.aufbau-tooltip-text {
    visibility: hidden;
    background-color: #333;
    color: #fff;
    text-align: center;
    border-radius: 4px;
    padding: 4px 8px;
    position: absolute;
    top: 125%;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 13px;
    white-space: nowrap;
    z-index: 10;
}

.aufbau-tooltip-text-right {
    visibility: hidden;
    background-color: #333;
    color: #fff;
    text-align: center;
    border-radius: 4px;
    padding: 4px 8px;
    position: absolute;
    top: 50%;
    left: 100%;
    transform: translateY(-50%);
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 13px;
    white-space: nowrap;
    z-index: 10;
    margin-left: 10px;
}

.aufbau-tooltip-text-left-top {
    visibility: hidden;
    background-color: #333;
    color: #fff;
    text-align: center;
    border-radius: 4px;
    padding: 4px 8px;
    position: absolute;
    top: -10%;
    left: 50%;
    transform: translateY(-50%);
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 13px;
    white-space: nowrap;
    z-index: 10;
    margin-right: 10px;
}


.aufbau-tooltip-wrapper:hover .aufbau-tooltip-text,
.aufbau-tooltip-wrapper:hover .aufbau-tooltip-text-left-top,
.aufbau-tooltip-wrapper:hover .aufbau-tooltip-text-right {
    visibility: visible;
    opacity: 1;
}


/* Portrait Media Query */
@media (orientation: portrait) {
    .login-div {
        position: absolute;
        top: 20px;
        transform: translate(-50%, 0%);
        width: 95%;
        border-color: #1919a8;
    }

    #login-box {
        position: relative;
        width: 95%;
    }


    .input-restrictions {
        max-width: 100px;
    }

    .tabs {
        display: none;
    }

    #toggleSidebarMobile {
        display: block;
        position: absolute;
        right: 10px;
        top: 10px;
    }

    #toggleSidebarX{
        display: none;
    }

    #hamburger-menu {
        display: block;
        position: absolute;
        left: 10px;
        top: 10px;
        text-align: center;
        background-color: transparent;
        border: none;
        font-size: 24px;
        color: #000;
        z-index: 500;
        width: 40px;
    }

    #hamburger-menu.open + .tabs {
        display: flex;
        flex-direction: column;
    }

    .tabs button {
        text-align: left;
        z-index: 550;
        background-color: white;
        color: black;
        width: 100%;
        border-width: 0;
        text-align: center;
    }

    .sidebar {
        position: fixed;
        top: 0;
        right: 0;
        width: 100%;
        height: 100%;
        z-index: 400;
        overflow-y: auto;
    }

    .sidebar-bg {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(245, 245, 245, 0.975);
        overflow-y: auto;
    }

    .sidebarControlButtons {
        display: flex;
        position: absolute;
        top: 20px;
        left: 50%;
        transform: translateX(-50%);
        flex-direction: row;
        z-index: 450;
    }

    .navibar {
        position: absolute;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        background: white;
        padding: 10px;
        z-index: 150;
        width: 75%;
    }

    .table-container {
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

}