/****************************
 * AWS Search v1.0
****************************/
:root {
    --aws-font-size:16px;
    --aws-text-color:var(--twc-color-text);
    --aws-height:65px;
    --aws-width:600px;
    --aws-thumb-size:60px;
}

/* custom scrollbar */
/* Works on Chrome, Edge, and Safari */
body .aws-search-result *::-webkit-scrollbar {width:7px;}
body .aws-search-result *::-webkit-scrollbar-track {background:var(--twc-color-gray);}
body .aws-search-result *::-webkit-scrollbar-thumb {background-color:var(--twc-color-primary);}


/* Wrapper */
html.search-open {overflow:hidden; padding-right:var(--twc-scroll-bar-width);}
html:not(.search-open) .twc-aws-search {opacity:0; visibility:hidden;}
.twc-aws-search {
    width:100%; height:100vh;
    background:rgba(0, 38, 81, 0.6);
    padding:24vh var(--twc-gap-container) 0;
}

/* Form */
.twc-aws-search__form {width:100%; max-width:var(--aws-width);}

.twc-aws-search .aws-container .aws-search-form {
    height:auto; position:relative; background:none; width:100%;
    border-radius:15px; overflow:hidden;
}
.twc-aws-search .aws-container .aws-search-form .aws-form-btn {display:none;}


/****************************
 * AWS Search - Form
****************************/
/* AWS Search > Form > Search icon */
.twc-aws-search .aws-container .aws-search-form:before {
    content:"\e920"; font-family:var(--twc-font-icomoon); font-size:var(--aws-font-size);
    position:absolute; top:0; bottom:0; right:0; z-index:20;
    transition:all .3s ease;
    background:var(--twc-color-dark-blue); color:var(--twc-color-on-primary);
    pointer-events:none; width:60px;
    display:flex; align-items:center; justify-content:center;
}
.twc-aws-search .aws-container .aws-search-form.aws-processing:before,
.twc-aws-search .aws-container .aws-search-form.aws-show-clear.aws-form-active:before {opacity:0;}

/* AWS Search > Form > Focus (input focus) */
.twc-aws-search .aws-container .aws-search-form.aws-focus {}

/* AWS Search > Form > Active (has query and is focus) */
.twc-aws-search .aws-container .aws-search-form.aws-form-active {}

/* AWS Search > Form > Processing (ajax loading) */
.twc-aws-search .aws-container .aws-search-form.aws-processing {}

/* AWS Search > Form > Focus (show clear) */
.twc-aws-search .aws-container .aws-search-form.aws-show-clear {}


/* AWS Search > Search input field */
.twc-aws-search .aws-container .aws-search-field {
    height:var(--aws-height); width:100%; padding:5px 20px;
    background:#f5f6f8; border-radius:10px !important;
    border:none; transition:var(--twc-transition);
    font-size:var(--aws-font-size); font-weight:500; color:var(--aws-text-color);
}
.twc-aws-search .aws-container .aws-search-field:hover,
.twc-aws-search .aws-container .aws-search-field:focus {

}


/****************************
 * AWS Search - Results Wrapper
****************************/
body .aws-search-result {
    font-size:14px;
    border:1px solid #ccc; background:#fff; border-radius:5px !important; overflow:hidden; margin-top:3px;
}
body .aws-search-result .aws_result_scroll {
    max-height:500px; overflow:auto;
}


/****************************
 * AWS Search - Results Item
****************************/
body .aws-search-result .aws_results .aws_result_item {
    padding:10px; border-color:#c6cfdb;
    display:flex; align-items:center; gap:15px;
}

/* content > head */
body .aws-search-result .aws_result_head {
    font-size:15px; font-weight:700; color:var(--twc-color-text);
    display:flex; flex-direction:column;
}

/* search keyword highlight */
body .aws-search-result .aws_result_title strong {background-color:yellow; color:#000;}

/* price */
body .aws-search-result .aws_result_price {display:flex; gap:10px; color:var(--twc-color-primary);}
.aws-search-result .aws_result_price del {opacity:.5;}
.aws-search-result .aws_result_price ins {}

/* image */
.aws-search-result .aws_result_image {
    width:var(--aws-thumb-size);
    box-shadow:0 0 0 1px #ccc; border-radius:4px; overflow:hidden;
}
.aws-search-result .aws_result_image img {
    object-fit:contain; object-position:center;
}


/* Sale badge */
.aws-search-result .aws_result_sale {
    position:absolute; top:20px; right:20px;
    transform:translate(50%, -50%) rotate(45deg); transform-origin:center;
    width:100px; background:var(--twc-color-primary); color:var(--twc-color-on-primary);
    text-align:center;
}


/* AWS Search > Search more button */
body .aws-search-result.aws_no_result .aws_results .aws_result_item,
body .aws-search-result .aws_results .aws_result_item.aws_search_more {
    background:var(--twc-color-primary); color:#fff; border:none; padding:5px 15px; min-height:55px;
    display:flex; align-items:center; justify-content:center;
    text-align:center; text-decoration:none; line-height:1.2;
    font-size:16px; font-family:var(--twc-font-primary); font-weight:400;
}

/* AWS Search > No result button */
body .aws-search-result.aws_no_result .aws_results .aws_result_item {background:var(--twc-color-primary);}

body .aws-search-result .aws_results .aws_result_item.aws_search_more:hover,
body .aws-search-result .aws_results .aws_result_item.aws_search_more:focus,
body .aws-search-result.aws_no_result .aws_results .aws_result_item:hover,
body .aws-search-result.aws_no_result .aws_results .aws_result_item:focus {
    background:var(--twc-color-dark-blue); color:#fff;
}


/****************************
 * AWS Search Responsive
****************************/
@media only screen and (max-width:1280px) {
    .twc-aws-search.desktop {display:none;}
    .twc-aws-search {padding-top:150px;}
}
@media only screen and (max-width:768px) {
    :root {
        --aws-thumb-size:45px;
        --aws-height:55px;
    }
}