/* Set base font size for the form and results */
#custom-search-form,
#custom-search-form input,
#custom-search-form button,
#custom-search-results,
.custom-search-dropdown,
.custom-search-item,
.custom-search-item a,
.custom-excerpt,
.custom-dropdown-header,
#custom-search-loading {
    font-size: 12px !important;
    border-radius: 0;
    padding: 3px 0 0 5px;
    width: 300px;
}


.custom-search-dropdown {
    max-height: 250px; /* smaller height */
    overflow-y: auto;
    overflow-x: hidden;
    background: white;
    border: 1px solid #ccc;
    position: absolute; /* <- makes it overlap */
    top: 100%; /* shows just below the input field */
    left: 0;
    z-index: 9999;
    padding: 0;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    animation: slideDown 0.3s ease-out;
    top: 38px;
    left: 5px;
    width: 200%;
    font-family: "AvenirNextLTPro-MediumCn", Sans-serif;
}

#custom-search-form {
    position: relative; /* makes result box position relative to the form */
}

.custom-dropdown-header {
    background-color: #4b2e83;
    color: white;
    padding: 10px;
    font-weight: bold;
    width: 100%;
    font-family: "AvenirNextLTPro-MediumCn", Sans-serif;
}

.custom-search-item {
    padding: 10px;
    border-bottom: 1px solid #ccc;
    width: 100%;
    font-family: "AvenirNextLTPro-MediumCn", Sans-serif;
}

.custom-search-item a {
    text-decoration: none;
    font-weight: bold;
    color: #492E8D;
    display: block;
    margin-bottom: 5px;
    font-family: "AvenirNextLTPro-MediumCn", Sans-serif !important;
}

.custom-excerpt {
    color: #333;
    font-size: 14px;
    width: 100%;
    font-family: "AvenirNextLTPro-MediumCn", Sans-serif;
}

#custom-search-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(255, 255, 255, 0.6); /* semi-transparent white */
    z-index: 9998;
    cursor: wait;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#custom-search-loading {
    font-size: 14px;
    color: #666;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% { opacity: 0.3; }
    50% { opacity: 1; }
    100% { opacity: 0.3; }
}
