/* WP Immo Search - Search Filter Styles (from original frontend.css) */

/* Search Filter Enhancements */
.wp-immo-search-filter {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: 1px solid #e9ecef;
    border-radius: 16px;
    padding: 32px;
    margin-bottom: 32px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    position: relative;
}

.wp-immo-search-filter::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #007cba, #4a90e2);
    border-radius: 16px 16px 0 0;
}

.immo-search-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.filter-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.filter-group {
    flex: 1;
    min-width: 220px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.filter-group label {
    font-weight: 600;
    color: #2c3e50;
    font-size: 14px;
    margin-bottom: 4px;
}

.filter-group input,
.filter-group select {
    padding: 14px 16px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-size: 14px;
    background: white;
    transition: all 0.3s ease;
    font-family: inherit;
}

.filter-group input:focus,
.filter-group select:focus {
    outline: none;
    border-color: #007cba;
    box-shadow: 0 0 0 3px rgba(0, 124, 186, 0.1);
    transform: translateY(-1px);
}

.filter-group input::placeholder {
    color: #6c757d;
}

/* Location Input with Autocomplete */
.location-input-wrapper {
    position: relative;
}

.location-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 2px solid #e9ecef;
    border-top: none;
    border-radius: 0 0 10px 10px;
    max-height: 240px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.location-suggestions.show {
    display: block;
}

.location-suggestion {
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid #f1f3f4;
    transition: all 0.2s ease;
    font-size: 14px;
}

.location-suggestion:hover,
.location-suggestion.active {
    background: #f8f9fa;
    color: #007cba;
}

.location-suggestion:last-child {
    border-bottom: none;
}

/* Range Slider Styling */
.radius-slider-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
}

.radius-slider-wrapper input[type="range"] {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: #e9ecef;
    outline: none;
    padding: 0;
    margin: 0;
    border: none;
    -webkit-appearance: none;
}

.radius-slider-wrapper input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #007cba;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease;
}

.radius-slider-wrapper input[type="range"]::-webkit-slider-thumb:hover {
    background: #005a87;
    transform: scale(1.1);
}

.radius-slider-wrapper input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #007cba;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.radius-display {
    font-weight: 700;
    color: #007cba;
    min-width: 60px;
    text-align: center;
    font-size: 16px;
}

/* Price, Area, Room Input Groups */
.price-inputs,
.area-inputs,
.room-inputs {
    display: flex;
    align-items: center;
    gap: 12px;
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 4px;
    transition: all 0.3s ease;
}

.price-inputs:focus-within,
.area-inputs:focus-within,
.room-inputs:focus-within {
    border-color: #007cba;
    box-shadow: 0 0 0 3px rgba(0, 124, 186, 0.1);
}

.price-inputs input,
.area-inputs input,
.room-inputs input {
    flex: 1;
    border: none;
    padding: 10px 12px;
    font-size: 14px;
    background: transparent;
    min-width: 0;
}

.price-inputs input:focus,
.area-inputs input:focus,
.room-inputs input:focus {
    outline: none;
    border: none;
    box-shadow: none;
    transform: none;
}

.price-separator,
.area-separator,
.room-separator {
    color: #6c757d;
    font-size: 14px;
    font-weight: 500;
    padding: 0 4px;
}

.price-currency,
.area-unit {
    color: #495057;
    font-size: 14px;
    font-weight: 600;
    padding: 0 8px;
}

/* Action Buttons */
.filter-actions {
    display: flex;
    gap: 16px;
    justify-content: flex-end;
    margin-top: 16px;
}

.search-button,
.reset-button {
    padding: 14px 28px;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
}

.search-button {
    background: linear-gradient(135deg, #007cba 0%, #4a90e2 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(0, 124, 186, 0.3);
}

.search-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 124, 186, 0.4);
}

.search-button:active {
    transform: translateY(0);
}

.reset-button {
    background: #f8f9fa;
    color: #6c757d;
    border: 2px solid #e9ecef;
}

.reset-button:hover {
    background: #e9ecef;
    color: #495057;
    border-color: #dee2e6;
}

/* Search Status */
.search-status {
    margin-top: 20px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 10px;
    text-align: center;
    border: 1px solid #e9ecef;
}

.search-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: #6c757d;
}

.loading-spinner {
    width: 18px;
    height: 18px;
    border: 2px solid #e9ecef;
    border-top: 2px solid #007cba;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}


/* Debug Panel Styles (aus frontend.js ausgelagert) */
#wp-immo-debug-panel {
    margin-top: 40px;
    padding: 20px;
    background: #f8f9fa;
    border: 2px solid #dee2e6;
    border-radius: 12px;
    font-family: 'Courier New', monospace;
    font-size: 12px;
    line-height: 1.4;
    max-width: 100%;
    overflow: hidden;
}

.debug-header {
    background: linear-gradient(135deg, #007cba 0%, #4a90e2 100%);
    color: white;
    padding: 16px 20px;
    margin: -20px -20px 20px -20px;
    border-radius: 12px 12px 0 0;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.debug-controls {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.debug-controls button {
    background: rgba(255,255,255,0.2);
    border: 1px solid rgba(255,255,255,0.3);
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.debug-controls button:hover {
    background: rgba(255,255,255,0.3);
    transform: translateY(-1px);
}

.debug-controls button.copied {
    background: #28a745;
    border-color: #28a745;
}

.debug-system-info {
    background: #e9ecef;
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 16px;
    font-size: 11px;
    border-left: 4px solid #6c757d;
}

.debug-entries {
    max-height: 500px;
    overflow-y: auto;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 16px;
    background: white;
}

.debug-entry {
    margin-bottom: 8px;
    padding: 8px 12px;
    border-radius: 6px;
    word-wrap: break-word;
    border-left: 4px solid #007cba;
    background: rgba(0, 124, 186, 0.05);
}

.debug-info {
    background: rgba(0, 124, 186, 0.05);
    border-left-color: #007cba;
}

.debug-warning {
    background: rgba(255, 193, 7, 0.1);
    border-left-color: #ffc107;
    color: #856404;
}

.debug-error {
    background: rgba(220, 53, 69, 0.1);
    border-left-color: #dc3545;
    color: #721c24;
}

.debug-time {
    display: inline-block;
    margin-right: 12px;
    opacity: 0.7;
    font-size: 10px;
    font-weight: bold;
    min-width: 80px;
    color: #6c757d;
}

.debug-message {
    word-break: break-word;
    white-space: pre-wrap;
}

/* Search Error Styles (aus frontend.js ausgelagert) */
.search-error {
    text-align: center;
    padding: 40px 20px;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
    color: #721c24;
}

.search-error h3 {
    margin-top: 0;
    color: #721c24;
}

.search-error button {
    margin: 8px;
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.retry-search {
    background: #007cba;
    color: white;
}

.retry-search:hover {
    background: #005a87;
}

.show-debug {
    background: #6c757d;
    color: white;
}

.show-debug:hover {
    background: #545b62;
}

/* Mobile Responsive für Debug Panel */
@media (max-width: 768px) {
    #wp-immo-debug-panel {
        margin-top: 20px;
        padding: 16px;
        font-size: 11px;
    }
    
    .debug-header {
        margin: -16px -16px 16px -16px;
        padding: 12px 16px;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .debug-controls {
        width: 100%;
        justify-content: flex-start;
    }
    
    .debug-entries {
        max-height: 300px;
        padding: 12px;
    }
    
    .debug-time {
        display: block;
        margin-bottom: 4px;
        margin-right: 0;
    }
}