/* Search page styles (extends sales.css for header/layout) */

#search-content {
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    padding: 20px 24px 40px;
}

/* Filter bar */
#search-filters {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 14px 18px;
    margin-bottom: 16px;
}
.filter-row-top {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: flex-end;
}
#search-filters .filter-group {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
#search-filters .filter-group label {
    font-size: 10px;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 3px;
}
#search-filters select,
#search-filters input[type="text"] {
    padding: 7px 8px;
    font-size: 13px;
    border: 1px solid #ddd;
    border-radius: 5px;
    background: #f9fafb;
    outline: none;
    min-width: 90px;
}
#search-filters select:focus,
#search-filters input:focus {
    border-color: #3388ff;
    background: white;
}
.filter-range {
    display: flex;
    align-items: center;
    gap: 4px;
}
.filter-range select {
    min-width: 75px;
}
.range-sep {
    color: #bbb;
    font-size: 14px;
}
.filter-group-btn {
    padding-top: 0;
}
#search-filters input[type="text"] {
    width: 100px;
}
.cb-label {
    display: flex !important;
    align-items: center;
    gap: 5px;
    font-size: 12px !important;
    color: #555 !important;
    text-transform: none !important;
    cursor: pointer;
    white-space: nowrap;
    padding-top: 6px;
}
.cb-label input[type="checkbox"] {
    min-width: auto;
    width: auto;
}

/* Info tooltip */
.info-tip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #ddd;
    color: #666;
    font-size: 9px;
    font-weight: 700;
    font-style: italic;
    cursor: help;
    vertical-align: middle;
    margin-left: 2px;
    position: relative;
}
.info-tip:hover {
    background: #3388ff;
    color: white;
}
#filter-apply {
    padding: 7px 20px;
    font-size: 13px;
    font-weight: 600;
    color: white;
    background: #3388ff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.15s;
}
#filter-apply:hover { background: #2266cc; }
.btn-clear {
    padding: 7px 14px;
    font-size: 13px;
    color: #666;
    background: white;
    border: 1px solid #ddd;
    border-radius: 5px;
    cursor: pointer;
}
.btn-clear:hover { background: #f5f5f5; }

/* Results count */
#results-count {
    font-size: 13px;
    color: #666;
    margin-bottom: 10px;
    min-height: 20px;
}

/* Results table */
#results-table-wrap {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    overflow-x: auto;
}
#results-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
#results-table thead th {
    background: #f9fafb;
    padding: 10px 14px;
    text-align: left;
    font-weight: 600;
    font-size: 12px;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    border-bottom: 1px solid #e5e7eb;
    white-space: nowrap;
}
#results-table thead th.num { text-align: right; }
#results-table tbody td {
    padding: 10px 14px;
    border-bottom: 1px solid #f0f0f0;
    color: #333;
}
#results-table tbody td.num { text-align: right; font-variant-numeric: tabular-nums; }
#results-table tbody td.empty {
    text-align: center;
    color: #999;
    padding: 40px 14px;
}
#results-table tbody tr {
    cursor: pointer;
    transition: background 0.1s;
}
#results-table tbody tr:hover { background: #f0f7ff; }

.addr-link {
    color: #3388ff;
    font-weight: 600;
    text-decoration: none;
}
.addr-link:hover { text-decoration: underline; }

.flood-pill {
    display: inline-block;
    padding: 1px 6px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 600;
}
.flood-pill.hazard {
    background: #fef2f2;
    color: #dc2626;
}
.flood-pill.safe {
    background: #f0fdf4;
    color: #16a34a;
}

/* Mobile */
@media (max-width: 768px) {
    #search-content { padding: 12px; }
    #search-filters { padding: 12px; gap: 8px; }
    #search-filters select,
    #search-filters input[type="text"] { min-width: 0; font-size: 12px; }
    .filter-group-text input { width: 100px; }
    #results-table { font-size: 12px; }
    #results-table thead th,
    #results-table tbody td { padding: 8px 10px; }
}
