
#algolia-search-form {
    display: flex;
    margin-right: auto;
    position: relative;
    /*margin-left: 10px;    */
    background-color: #f0f0f0;
    padding: 6px;
    border-radius: 7px;
}

#clear_input_field_algolia_search_bar {
    border: unset;
    background-color: white;
    font-size: 20px;
    color: #bebebe;
    /* color: red; */
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 20px;
    margin-left: -20px;
    display: none;
    margin-top: 1px;
    margin-bottom: 1px;
    padding: 0 10px 0 0px;
    cursor: pointer;
    z-index: 2;
}

#algolia_filtering_results_on_curr {
    /* background-color: #f4f4f4; */
    font-weight: 500;
    color: #96beff;
    padding: 4px 0px;
    /* border-radius: 6px; */
    display: flex;
    gap: 0px 10px;
    width: 100%;
    justify-content: flex-start;
    align-items: center;
    padding-left: clamp(0px, 1vw, 10px);
    flex-wrap: wrap;
    /*
    border-top: solid 1.5px lightgrey;
    border-bottom: solid 1.5px lightgrey;
    */

}

#algolia_filtering_results_on_curr > div {
    cursor: pointer;
    display: flex;    
    padding: 3px 6px;
    border-radius: 4px;    
}

.count_search_hits:not(:empty)::before {
    content: "(";
}

.count_search_hits:not(:empty)::after {
    content: ")";
}


#algolia_filtering_results_on_curr > div:hover {
    color: #ffffff;
    background-color: #d1d1d1;    
    background-color: #ecf6ff;
    color: #5890ea;
}


#algolia_filtering_results_on_curr > div.active {        
    background-color: #ecf6ff;
    color: #5890ea;
}


#algolia-results{
    max-width: 500px;
    max-height: 55vh;        
    overflow: auto; 
    padding: 10px 0px;
    overflow-y: scroll;
    scrollbar-gutter: stable both-edges; /* stable, or stable both-edges */
    min-height: 130px;
}

#algolia-results::-webkit-scrollbar {
    width: 10px;
}

#algolia-results::-webkit-scrollbar-thumb {
    border-radius: 12px;
    background-color: #ededed;
}

.search-result {    
    cursor: pointer;
    padding: 12px 10px;
    border-radius: 5px;
    margin: 0px 13px 0px 4px;
    position: relative;
    display: flex;
    flex-wrap: nowrap; 
    justify-content: space-between;
    align-items: flex-start;
    flex-direction: column;
    width: fit-content;
}

.search-result:hover {
    box-shadow: 0px 0px 6px 0px #c2c2c2;    
}

.wrapper_header_search_hit {
    display: flex;
    gap: 10px;    
    align-items: flex-end;
}

.search_hit_post_title {
    font-size: 14px;
    font-weight: 600;
    height: 20px;
    line-height: 20px;
    color: #4c7cd7;
}

.search_hit_vimeo_duration {
    font-size: 10px;
    font-weight: 400;
    height: 20px;
    line-height: 20px;
    color: grey;
    margin-bottom: -1px;
}

.search_hit_post_content {    
    max-width: 250px;
}


.search_hit_post_content img {    
    max-width: 100px;
}

.search_hit_transcript {
    padding: 10px 0px;
    max-width: 390px;
    display: none;
}

.search_hit_action_tabs {
    border-radius: 5px;
    padding: 6px 15px;
    max-width: 240px;
    background-color: #ecf6ff;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    line-height: 8px;
    border: solid 2px #ecf6ff;
    font-size: clamp(8px, 0.9vw, 10px);
    white-space: nowrap;
}

.search_hit_action_tabs:hover {
    border: solid 2px #bde0ff;
}

.wrapper_search_hit_top_part {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
    justify-content: space-between;
    width: 100%;
}

.wrapper_search_preview_card {
    padding-right: 10px;
}

.wrapper_search_hit_action_tabs_and_hit_data {
    position: relative;
}

/* Default state: instant (no transition) */
.wrapper_search_hit_action_tabs {
    opacity: 0;
    padding-top: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;     
  }

.wrapper_search_hit_count_of_keyword_hits {    
    width: 100%;
    height: 100%;
    top: 0;
    opacity: 1;
    padding-top: 0;
    display: flex;
    flex-direction: row;
    justify-content: end;
    gap: 15px;
    padding: 12px 0px 0px 5px;
  }
  
/* Hovered state: smooth (with transition) */
.search-result:hover .wrapper_search_hit_action_tabs {
    /* Add the transitions only when it expands */
    transition: max-height 0.6s ease, opacity 0.6s ease;
    max-height: 200px;
    opacity: 1;   
    display: flex; 
}

.search_hit_count_of_keyword_hits {        
    line-height: 10px;
    color: #aeaeae;
    font-size: 11px;    
    transition: color 0.3s ease; /* <— add this */
}

.search-result:hover .search_hit_count_of_keyword_hits {        
    color: #d3d3d3;
}


#algolia-query {
    background-color: white;
    border: unset;    
    padding-left: 10px;
    /*padding-right: 25px;*/
    line-height: 30px;
    color: #545454 !important;
    z-index: 1;
    font-size: 16px;
}

#algolia-query:hover {
    outline: solid black 2px;
}

/* Removes the outline and border when focused */
#algolia-query:focus {
    outline: none !important;
    border: none !important;
    box-shadow: none !important;
  }
  
.butto_search_algolia_modal {
    outline: none;
    border: none;
    background-color: #f0f0f0;
}

.algolia_search_transcript_timecode {
    display: inline;
    font-weight: 500;
    margin-right: 5px;
}

.algolia_search_transcript_text_section {
    margin-top: 10px;
}

.search-result em {
    background-color: #f7ff2d;
    color: #444444;
    font-style: italic;
    padding: 0px 6px 0px 2px;
}

.button_to_display_hidden_search_results {
    position: relative;    
    padding: 5px 10px;
    background-color: aliceblue;
    border-radius: 5px;
    color: #5890ea;
    cursor: pointer;
    border: solid aliceblue 2px
}

.button_to_display_hidden_search_results:hover {
    border: solid #5890ea 2px
}

.search_hit_permalink {
    background-color: darkgrey; 
    color: white; 
    margin: 10px 0px; 
    display: none;
}

.wrapper_search_hit_action_tabs_and_hit_data {
    display: flex;
    align-items: stretch;
}

#minimized_algolia_search_form {
    margin: unset;
}

#clear_search_results_in_algolia_modal {        
    left: 100%;
    line-height: 10px;
    margin-top: 3px;
    height: 100%;
    display: flex;
    align-items: end;
    white-space: nowrap;
    padding: 4px 6px;
    font-size: 10px;
    color: #bdbdbd;
    cursor: pointer;
    z-index: 2;
}

#clear_search_results_in_algolia_modal:hover {    
    text-decoration: underline;
}

.search_hit_sub_chapter_name {
    color: #bdbdbd;
}

#container_for_book_selector_active_book {
    font-size: clamp(9px, 0.85vw, 12px);
    color: #838383;
    font-weight: 400;
}

#container_for_book_selector_tab:hover #container_for_book_selector_active_book {    
    color: white;        
    color: #181818 ;
}

/* Container of the suggestions dropdown */
.ui-autocomplete {
    background-color: #fff; 
    border: 1px solid #ccc;
    max-height: 200px; 
    overflow-y: auto;
    overflow-x: hidden;      /* Hide horizontal scrollbar */
    white-space: normal;     /* Let text wrap onto multiple lines */
    word-wrap: break-word;   /* Ensure long words can break to next line */
    padding: 0;            
    margin: 0;             
    list-style: none;
    z-index: 9999;          /* Make sure it appears on top of other elements */
    font-size: calc(clamp(11px, 0.95vw, 14px)* 0.9) !important;
    font-family: roboto !important;    

}

.ui-autocomplete::-webkit-scrollbar {
    width: 10px;
}

.ui-autocomplete::-webkit-scrollbar-thumb {
    border-radius: 12px;
    background-color: #ededed;
}
  
/* Each suggestion row */
.ui-autocomplete .ui-menu-item-wrapper {
    padding: 8px 12px;
    cursor: pointer;
}

/* Highlighted item (hover/keyboard focus) */
.ui-autocomplete .ui-state-focus {
    background-color: #efefef;
}

.algolia_search_welcome_illustration_wrapper {    
    border-radius: 13px;    
    background-color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 7px;
}

.algolia_search_welcome_illustration {
    display: flex;
    padding-top: 30px;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    position: relative;
    z-index: 3;
    background-color: white;
    width: 100px;
    /* height: 100%; */
    border-radius: clamp(20px, 2.4vw, 40px);
    /* min-height: clamp(600px, 55vw, 700px);*/
}

.container_iframe_algolia_search_welcome_text {
    margin: 0 auto;    
    color: #a6a6a6;
    font-size: clamp(10px, 1vw, 14px);
}


.container_algolia_search_loader_illustration {
    display: flex;
    padding-top: clamp(20px, 3vw, 40px);
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    position: relative;
    z-index: 3;
    background-color: white;
    width: 100%;
    height: 100%;
    border-radius: clamp(20px, 2.4vw, 40px);
    /* min-height: clamp(600px, 55vw, 700px); */
    padding-bottom: clamp(20px, 1vw, 0px);    
}

.container_algolia_search_loader_illustration_wrapper {    
    border-radius: 13px;    
    background-color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 7px;
    /*box-shadow: 0px 0px 8px 2px #e9e9e9;*/
}

.container_iframe_algolia_search_loader_image {
    margin: 0 auto;    
    width: clamp(80px, 9vw, 100px);
    width: 45px;
}

.container_iframe_algolia_search_loader_text {
    margin: 0 auto;    
    color: #a6a6a6;
    font-size: clamp(10px, 1vw, 14px);
}

.notification_no_hits_in_active_curr {
    margin-bottom: 10px;
    color: #929292;
}
          


@media screen and (max-width: 480px) {    
    .search_hit_action_tabs {        
        white-space: wrap;
    }   
}