html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    font-size: 13.5px;
    line-height: 1.14;
}

select, input {
    font-size: 12.5px;
}

#main-content {
    width: 85%;
    margin: 15px auto;
    padding: 15px;
    background-color: rgba(255, 255, 255, 0.99);
    box-sizing: border-box;
    max-width: 1800px;
}

.visualization-title {
    margin: 0.3em 0;
}

p {
    margin: 0.15em 0;
}

/* ===================== Table (unchanged) ===================== */

.table-container {
    overflow-x: auto;
}

.hazard-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 12.5px;
}

.hazard-table th,
.hazard-table td {
    border: 1.5px solid #CDCDCD;
    padding: 1.5px;
    text-align: left;
}

.hazard-table th {
    background-color: #e6EEEE;
    font-size: 13px;
    padding: 3px;
    padding-right: 20px;
}

.hazard-table tr.response:hover {
    background-color: #FFCC66 !important;
    color: #663399;
}

.th-placeholder {
    background-color: transparent !important;
    border: none !important;
}

.th-top {
    background-color: white !important;
    color: #4a6ea9 !important;
    text-transform: uppercase !important;
    font-weight: bold !important;
    border: 1px solid #4a6ea9 !important;
    padding: 2px !important;
    text-align: center !important;
}

.hazard-table th.th-sortable {
    background-image: url(bg.gif);
    background-repeat: no-repeat;
    background-position: center right;
    cursor: pointer;
}

.hazard-table th.th-sortable:hover {
    background-color: #8dbdd8;
}

.hazard-table th.th-sort-asc {
    background-image: url(desc.gif);
}

.hazard-table th.th-sort-desc {
    background-image: url(asc.gif);
}

.hazard-table th.th-sort-asc,
.hazard-table th.th-sort-desc {
    background-color: #FFCC66 !important;
}

.hazard-table tr:nth-child(even) {
    background-color: rgba(242, 242, 242, 0.7);
}

.hazard-table a {
    color: #4a6ea9;
    text-decoration: none;
}

.hazard-table a:hover {
    text-decoration: underline;
}

/* ===================== Responsive ===================== */

@media screen and (max-width: 1200px) {
    .search-row .form-group {
        flex: 1 1 calc(50% - 4px);
        max-width: calc(50% - 4px);
    }
    .event-group {
        flex: 1 1 calc(100% - 4px);
        max-width: calc(100% - 4px);
    }
    .hazard-table {
        font-size: 12px;
    }
}

@media screen and (max-width: 768px) {
    .search-row .form-group {
        flex: 1 1 100%;
        max-width: 100%;
    }

    #main-content {
        width: 95%;
        padding: 10px;
    }

    .form-group label {
        flex: 0 0 120px;
    }

    select, input {
        font-size: 11.5px;
    }

    .hazard-table {
        font-size: 10.5px;
    }

    .hazard-table th,
    .hazard-table td {
        padding: 2px;
    }
}

@media screen and (max-width: 480px) {
    .button-group {
        flex-direction: column;
    }

    .search-btn,
    .reset-btn {
        width: 100%;
    }

    .form-group label {
        flex: 0 0 100px;
    }

    .hazard-table th,
    .hazard-table td {
        padding: 2px;
    }

    select, input {
        font-size: 10.5px;
    }
}

select option:disabled {
    color: #999;
    background-color: #f0f0f0;
}

