/* css/tcm-style.css */
#tcm-map {
    width: 100%;
    height: 500px;
    border: 1px solid #ccc;
    border-radius: 8px;
    background-color: #f9f9f9;
    margin-bottom: 20px; /* Add space between map and table */
}

/* Filter Dropdown Styles */
.tcm-filter-container {
    margin-bottom: 15px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.tcm-filter-dropdown {
    position: relative;
    display: inline-block;
}
.tcm-filter-button {
    background-color: #f2f2f2;
    color: #333;
    padding: 10px 20px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 4px;
    cursor: pointer;
}
.tcm-filter-options-content {
    display: none;
    position: absolute;
    background-color: #f9f9f9;
    min-width: 200px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 100;
    border: 1px solid #ddd;
    border-radius: 4px;
    max-height: 300px;
    overflow-y: auto;
    padding: 10px;
}
.tcm-filter-options-content.show {
    display: block;
}
.tcm-filter-options-content label {
    display: block;
    padding: 8px 12px;
    cursor: pointer;
    white-space: nowrap;
}
.tcm-filter-options-content label:hover {
    background-color: #f1f1f1;
}
.tcm-filter-all-options {
    padding: 8px 12px;
    border-bottom: 1px solid #ddd;
    margin-bottom: 5px;
}
.tcm-filter-all-options a {
    color: #0073aa;
    text-decoration: none;
    font-weight: bold;
}
.tcm-filter-all-options a:hover {
    text-decoration: underline;
}
.tcm-filter-options-content input[type="checkbox"] {
    margin-right: 10px;
    vertical-align: middle;
    display: inline-block !important; 
    opacity: 1 !important;
    position: static !important;
}
.tcm-filter-search-input {
    width: calc(100% - 20px);
    padding: 8px 10px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

/* Custom Marker Styles */
.tcm-marker {
    background-image: conic-gradient(from 90deg at 25% -25%, rgb(255, 215, 0), rgb(247, 157, 3), rgb(238, 105, 7), rgb(230, 57, 10), rgb(222, 13, 13), rgb(214, 16, 57),rgb(238, 105, 7), rgb(247, 157, 3), rgb(255, 215, 0), rgb(255, 215, 0), rgb(255, 215, 0));
    border: 2px solid #ffffff;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}
.tcm-marker .material-symbols-outlined {
    font-size: 24px;
    color: #ffffff;
}


/* Infowindow Styles */
.tcm-infowindow {
    font-family: sans-serif;
    padding: 5px;
    max-width: 320px;
}
.tcm-infowindow-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}
.tcm-infowindow-title h3 {
    margin: 0;
    font-size: 1.2em;
}
.tcm-infowindow-title .material-symbols-outlined {
    font-size: 24px;
    vertical-align: middle;
}
.tcm-infowindow-table {
    width: 100%;
    border-collapse: collapse;
}
.tcm-infowindow-table td {
    padding: 1px;
    vertical-align: top;
}
.tcm-infowindow-table td:first-child {
    padding-right: 10px;
}

/* DataTable Styles */
.tcm-datatable-container {
    width: 100%;
    font-family: sans-serif;
}
#tcm-datatable {
    width: 100% !important;
    border-collapse: collapse;
}
.tcm-datatable-container #tcm-datatable thead th,
.tcm-datatable-container #tcm-datatable tbody td {
    word-break: normal !important;
    overflow-wrap: normal !important;
}
#tcm-datatable thead th {
    white-space: nowrap; /* Prevents wrapping for headers */
}
#tcm-datatable tbody td {
    white-space: normal; /* Allows content in body to wrap */
}
#tcm-datatable thead th {
    background-color: #f2f2f2;
    border-bottom: 2px solid #ddd;
    padding: 12px 15px;
    text-align: left;
    font-weight: bold;
}
#tcm-datatable tbody td {
    border-bottom: 1px solid #ddd;
    padding: 10px 15px;
}
#tcm-datatable tbody tr {
    cursor: pointer;
}
#tcm-datatable tbody tr:nth-child(even) {
    background-color: #f9f9f9;
}
.tcm-datatable-container #tcm-datatable tbody tr:hover {
    background-color: #f1f1f1 !important;
    color: inherit !important;
    background-image: none !important;
    box-shadow: none !important;
}

/* Icon Button Styles */
.tcm-icon-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background-color: #e0e0e0;
    color: #333;
    border-radius: 50%;
    text-decoration: none;
    transition: background-color 0.2s;
}
.tcm-icon-button:hover {
    background-color: #ccc;
    color: #000;
}
.tcm-icon-button .material-symbols-outlined {
    font-size: 20px;
}

/* Responsive Styles for the DataTable */
@media screen and (max-width: 768px) {
    .tcm-datatable-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    #tcm-datatable {
        white-space: nowrap;
    }
}