/* OE GP Lookup Plugin Stylesheet */

/* Results Dropdown Container - Starts hidden as agreed */
.oegpl-results-dropdown {
    display: none !important;
    margin-top: 10px !important;
    animation: oegpl-fadeIn 0.3s ease-out;
}

.oegpl-results-dropdown.active {
    display: block !important;
}

/* Premium styled Select box */
.oegpl-results-dropdown select {
    width: 100% !important;
    border: 1px solid #d1d5db !important;
    border-radius: 8px !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
    font-size: 13px !important;
    line-height: 1.5 !important;
    padding: 8px 12px !important;
    background-color: #ffffff !important;
    color: #1f2937 !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03) !important;
    outline: none !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
    overflow-y: auto !important;
}

.oegpl-results-dropdown select:focus {
    border-color: #4F46E5 !important;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.18) !important;
}

/* Custom styling for options within the select list */
.oegpl-results-dropdown select option {
    padding: 6px 8px !important;
    border-radius: 4px !important;
    margin-bottom: 2px !important;
    cursor: pointer !important;
    border-bottom: 1px solid #f3f4f6 !important;
    font-weight: 500 !important;
}

.oegpl-results-dropdown select option:last-child {
    border-bottom: none !important;
}

.oegpl-results-dropdown select option:hover,
.oegpl-results-dropdown select option:focus {
    background-color: #EEF2FF !important;
    color: #4F46E5 !important;
}

/* Scrollbar customization for the dropdown select */
.oegpl-results-dropdown select::-webkit-scrollbar {
    width: 6px;
}
.oegpl-results-dropdown select::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}
.oegpl-results-dropdown select::-webkit-scrollbar-thumb {
    background: #c7d2fe;
    border-radius: 4px;
}
.oegpl-results-dropdown select::-webkit-scrollbar-thumb:hover {
    background: #a5b4fc;
}

/* Premium In-field Loading Spinner */
.oegpl-search-name .ginput_container,
.oegpl-search-address .ginput_container {
    position: relative !important;
}

.oegpl-spinner {
    display: none;
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    border: 2px solid rgba(79, 70, 229, 0.2);
    border-radius: 50%;
    border-top-color: #4F46E5;
    animation: oegpl-spin 0.8s linear infinite;
    z-index: 10;
    pointer-events: none;
}

/* Adjust input padding so the text doesn't overlap the spinner */
.oegpl-search-name input[type="text"],
.oegpl-search-address input[type="text"] {
    padding-right: 40px !important;
}

@keyframes oegpl-spin {
    0% {
        transform: translateY(-50%) rotate(0deg);
    }
    100% {
        transform: translateY(-50%) rotate(360deg);
    }
}

@keyframes oegpl-fadeIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
