/* ==========================================================================
   Quick Search Frontend Styles (Minimalist Floating Search Bar)
   ========================================================================== */
.tbg-idx-quick-search-minimal {
    max-width: 800px;
    margin: 2rem auto;
    position: relative;
    z-index: 10;
}

.tbg-idx-qs-form {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 999px;
    /* Pill shape */
    padding: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0, 0, 0, 0.04);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.tbg-idx-qs-form:focus-within {
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.12), 0 2px 6px rgba(0, 0, 0, 0.06);
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(0, 0, 0, 0.15);
}

/* Common Font Overrides */
.tbg-idx-qs-input,
.tbg-idx-qs-select,
.tbg-idx-qs-btn {
    font-family: var(--tbg-idx-font-family, 'DM Sans', sans-serif);
    font-size: 16px;
    color: var(--tbg-idx-text-color, #1a1a1a);
}

/* Omnibox Text Input */
.tbg-idx-qs-input-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    padding-left: 16px;
    min-width: 0;
    /* Prevent overflow */
}

.tbg-idx-qs-icon {
    color: #9ca3af;
    margin-right: 12px;
    flex-shrink: 0;
}

.tbg-idx-qs-input {
    width: 100%;
    border: none;
    background: transparent;
    padding: 12px 0;
    font-weight: 500;
}

.tbg-idx-qs-input:focus {
    outline: none;
}

.tbg-idx-qs-input::placeholder {
    color: #9ca3af;
    font-weight: 400;
}

/* Divider line between input and select */
.tbg-idx-qs-divider {
    width: 1px;
    height: 28px;
    background-color: rgba(0, 0, 0, 0.1);
    margin: 0 16px;
    flex-shrink: 0;
}

/* Property Type Dropdown */
.tbg-idx-qs-select-wrapper {
    flex: 0 0 auto;
    min-width: 140px;
}

.tbg-idx-qs-select {
    width: 100%;
    border: none;
    background: transparent;
    padding: 12px 16px 12px 0;
    cursor: pointer;
    font-weight: 500;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' width='16' height='16' stroke='%239ca3af' stroke-width='2' fill='none' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 4px center;
    padding-right: 24px;
}

.tbg-idx-qs-select:focus {
    outline: none;
}

/* Submit Button */
.tbg-idx-qs-btn {
    flex: 0 0 auto;
    background: var(--tbg-idx-primary-color, #111);
    color: #fff;
    border: none;
    padding: 14px 28px;
    border-radius: 999px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-left: 8px;
}

.tbg-idx-qs-btn:hover {
    background: var(--tbg-idx-primary-hover, #333);
    transform: translateY(-1px);
}

/* Dark theme overrides */
[data-theme="dark"] .tbg-idx-qs-form,
.dark .tbg-idx-qs-form {
    background: rgba(30, 30, 30, 0.7);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .tbg-idx-qs-form:focus-within,
.dark .tbg-idx-qs-form:focus-within {
    background: rgba(30, 30, 30, 0.9);
    border-color: rgba(255, 255, 255, 0.2);
}

[data-theme="dark"] .tbg-idx-qs-input,
[data-theme="dark"] .tbg-idx-qs-select,
.dark .tbg-idx-qs-input,
.dark .tbg-idx-qs-select {
    color: #fff;
}

[data-theme="dark"] .tbg-idx-qs-select option,
.dark .tbg-idx-qs-select option {
    background: #1e1e1e;
    color: #fff;
}

[data-theme="dark"] .tbg-idx-qs-divider,
.dark .tbg-idx-qs-divider {
    background-color: rgba(255, 255, 255, 0.15);
}

[data-theme="dark"] .tbg-idx-qs-btn,
.dark .tbg-idx-qs-btn {
    background: #fff;
    color: #000;
}

[data-theme="dark"] .tbg-idx-qs-btn:hover,
.dark .tbg-idx-qs-btn:hover {
    background: #e5e7eb;
}

/* Mobile Responsiveness */
@media (max-width: 640px) {
    .tbg-idx-qs-form {
        flex-direction: column;
        border-radius: 16px;
        padding: 12px;
        align-items: stretch;
    }

    .tbg-idx-qs-divider {
        width: 100%;
        height: 1px;
        margin: 8px 0;
    }

    .tbg-idx-qs-input-wrapper {
        padding: 8px 12px;
    }

    .tbg-idx-qs-select-wrapper {
        padding: 8px 12px;
    }

    .tbg-idx-qs-select {
        padding: 8px 24px 8px 0;
    }

    .tbg-idx-qs-btn {
        margin: 12px 0 0 0;
        width: 100%;
        border-radius: 12px;
        padding: 16px;
    }
}