.banner {
    align-items:center;
    
    height: fit-content;
    /*background-color: #1e2130;*/
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #4B5460;
    margin-bottom: 20px;
    padding: 1rem 10rem;
    width: 100%;
}

#banner-text {
    text-align: left;
}

#banner h1{
    color: #191970;
}

#banner-logo {
    display: inline;

}

.banner-button {
    margin-right: 10px;
    height: 30px;
    color: #555;
    text-align: center;
    align-items: center;
    background-color: transparent;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .1rem;
    text-transform: uppercase;
    text-decoration: none;
    white-space: nowrap;
    border-radius: 4px;
    border: 1px solid #bbb;
    cursor: pointer;
    box-sizing: border-box;
    margin: 2px;
  }
  
  .banner Img {
    height: 4.5rem;
    margin: 0px 10px;
  }

#banner-buttons{
    display: flex;
    flex-direction: column;
    align-items:flex-end;
    justify-content: flex-end;
}

.banner-group {
    display: flex;
    flex-direction: row;
}

.sidebar {
    width: 100%;
    height: auto;
    background-color: #f8f9fa;
    padding: 10px;
    margin-bottom: 20px; /* Add margin to separate from the footer */
    text-align: center;
}

.sidebar h2{
    text-align: center;
    color: #191970;
}

.sidebar_buttons{
    display: table-column;
    justify-content: center;
    align-items: center;
    text-align: center;
    margin: 2em;
}

#start-datepicker{
    display: inline-block;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
    margin-left: 10px;
    margin-bottom: 20px;
}

#end-datepicker{
    display: inline-block;
    align-items: center;
    justify-content: center;
    margin-left: 10px;
}

.main-container {
    display: flex; /* Flexbox for side-by-side layout */
    justify-content: flex-start;
    width: 100%;
    overflow-x: hidden;  /* Prevent horizontal scroll on the main container */
}

.left-column {
    display: flex;
    flex-direction: column; /* Stack sidebar and footer vertically */
    margin-left: 1%;
    width: 30%; /* Sidebar and footer take 30% of the container's width */
    min-width: 300px;  /* Ensures sidebar doesn't get too narrow */
    flex-shrink: 0;    /* Prevents sidebar from shrinking */

}

.right-column {
    margin-left: 1%;
    margin-right: 1%;
    width: 80%;
    height: calc(100vh - 150px); /* Match table height */
    overflow-x: hidden;  /* Prevent horizontal scroll on the main container */
    overflow-y: auto;
}

.footer {
    justify-content: center;
    align-items: center;
    text-align: center;
    width: 100%; /* Full width of the container */
}

#ifremer{
    padding: 1em;
    height: 100%;
    width: 30%;
}

#cnrs{
    height: 100%;
    width: 20%;
}

.loading-component{
    margin-top: 50%;
    z-index: 99 !important;
}

.centered-table {
    width: 100%;
    border-collapse: collapse;
}
.centered-table th, .centered-table td {
    text-align: center;
    padding: 8px;
}
.centered-table th {
    background-color: #f2f2f2;
}

.tabs-dropdowns {
    margin-left: 25%;
    width: 50%;
    margin: 5px;
}

.logo {
    width: 90%;
    height: 100%;
}

/* Mobile-specific styles */
@media (max-width: 768px) {
    .banner {
        flex-direction: column;
        text-align: center;
        padding: 1rem;
    }

    #banner-text {
        text-align: center;
        margin-bottom: 1rem;
    }

    .banner-group {
        flex-direction: column-reverse;
        align-items: center;
    }

    #banner-buttons {
        align-items: center;
        margin-top: 1rem;
    }

    .banner Img {
        height: 3rem;
    }

    .main-container {
        flex-direction: column;  /* Stack on mobile */
    }

    .left-column {
        width: 98%;  /* Full width on mobile */
        margin: 0 1%;
    }

    .right-column {
        width: 98%;  /* Full width on mobile */
        margin: 0 1%;
    }

    #start-datepicker,
    #end-datepicker {
        width: 80% !important;
        margin: 5px auto;
        display: block;
    }

    .dash-table-container {
        overflow-x: auto;
    }

    .map-container,
    html.Embed {
        height: 300px;
    }

    .turtle-cards-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 10px;
        padding: 10px;
    }
}

/* Tablet-specific styles */
@media (min-width: 769px) and (max-width: 1024px) {
    .left-column {
        width: 35%;
    }

    .right-column {
        width: 63%;
    }

    .turtle-cards-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 250px));
    }
}

/* Touch device optimizations */
@media (hover: none) {
    .banner-button,
    .sidebar_buttons,
    .turtle-card {
        padding: 12px;
    }

    .turtle-card:hover {
        transform: none;
        box-shadow: none;
    }
}

/* Add this to your existing CSS */
#data-info-block {
    margin-bottom: 20px;
    padding: 10px;
}

#data-info-block p {
    margin: 5px 0;
    font-size: 0.9em;
}

#data-info-block h2 {
    margin-bottom: 10px;
}

.logger-cards-container {
    padding: 20px;
    width: 100%;
}

.logger-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 200px));
    gap: 20px;
    padding: 20px;
    max-width: 1350px;
}

.logger-card {
    transition: transform 0.2s;
    cursor: pointer;
}

.logger-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.logger-card img {
    height: 150px;
    object-fit: cover;
}

.map-container {
    order: 1;
    width: 100%;
    margin-bottom: 20px;
    min-height: 0;  /* Default height when empty */
    height: 500px;  /* Height when has content */
    display: none;  /* Hidden by default */
}

.map-container:not(:empty) {
    display: block;  /* Show only when has content */
}

/* Improve dropdown usability on mobile */
.Select-control {
    min-height: 38px;
}

.Select-menu-outer {
    max-height: 300px;
}

/* Ensure modals and popups are usable on mobile */
.modal-content {
    width: 90%;
    margin: auto;
    max-height: 80vh;
    overflow-y: auto;
}
