/* =========================================================
   SEARCH MODAL
   ========================================================= */

.search-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;

    display: none;

    font-family: 'Poppins', sans-serif;
}

.search-modal.is-open {
    display: block;
}


/* =========================================================
   BACKDROP
   ========================================================= */

.search-modal-backdrop {
    position: absolute;
    inset: 0;

    background: rgba(15, 23, 42, .62);

    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}


/* =========================================================
   MODAL
   ========================================================= */

.search-modal-card {
    position: relative;

    width: min(680px, calc(100% - 30px));

    margin: 8vh auto 0;
    padding: 24px;

    background: #ffffff;

    border: 1px solid rgba(15, 23, 42, .08);
    border-radius: 22px;

    box-shadow:
        0 30px 80px rgba(2, 6, 23, .28);

    animation: searchModalIn .22s ease;
}

@keyframes searchModalIn {

    from {
        opacity: 0;
        transform: translateY(-15px) scale(.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }

}


/* =========================================================
   HEADER
   ========================================================= */

.search-modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;

    gap: 20px;

    margin-bottom: 20px;
}

.search-modal-title-wrap {
    display: flex;
    flex-direction: column;

    gap: 3px;
}

.search-modal-kicker {
    margin: 0;

    color: #2563eb;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1px;
    text-transform: uppercase;
}

.search-modal-title {
    margin: 0;

    color: #0f172a;

    font-size: 20px;
    line-height: 1.25;

    font-weight: 800;
}

.search-modal-close {
    width: 34px;
    height: 34px;

    flex: 0 0 34px;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 0;

    border: 0;
    border-radius: 10px;

    background: #f8fafc;

    color: #475569;

    font-size: 18px;
    font-weight: 700;

    cursor: pointer;

    transition: .2s ease;
}

.search-modal-close:hover {
    background: #fee2e2;
    color: #dc2626;
}


/* =========================================================
   SEARCH FORM
   ========================================================= */

.search-modal-form {
    display: flex;
    align-items: center;

    gap: 10px;

    width: 100%;
}


/* =========================================================
   INPUT
   ========================================================= */

.search-modal-input {
    flex: 1;

    min-width: 0;

    height: 48px;

    padding: 0 15px;

    border: 1px solid rgba(15, 23, 42, .14);
    border-radius: 13px;

    background: #ffffff;

    color: #0f172a;

    font-family: inherit;
    font-size: 13px;

    outline: none;

    transition: .2s ease;
}

.search-modal-input::placeholder {
    color: #94a3b8;
}

.search-modal-input:hover {
    border-color: rgba(37, 99, 235, .25);
}

.search-modal-input:focus {
    border-color: #2563eb;

    box-shadow:
        0 0 0 3px rgba(37, 99, 235, .10);
}


/* =========================================================
   BUTTON
   ========================================================= */

.search-modal-submit {
    height: 48px;

    padding: 0 20px;

    border: 0;
    border-radius: 13px;

    background:
        linear-gradient(
            135deg,
            #2563eb,
            #10b981
        );

    color: #ffffff;

    font-family: inherit;

    font-size: 13px;
    font-weight: 700;

    cursor: pointer;

    transition: .2s ease;
}

.search-modal-submit:hover {
    transform: translateY(-1px);

    box-shadow:
        0 8px 20px rgba(37, 99, 235, .20);
}


/* =========================================================
   HINT
   ========================================================= */

.search-modal-hint {
    margin-top: 10px;

    color: #64748b;

    font-size: 11px;
    line-height: 1.5;
}


/* =========================================================
   RESULTS
   ========================================================= */

.search-modal-results {
    margin-top: 18px;
    padding-top: 18px;

    border-top: 1px solid rgba(15, 23, 42, .08);
}


/* =========================================================
   RESULT HEADING
   ========================================================= */

.search-results-heading {
    margin-bottom: 10px;

    color: #64748b;

    font-size: 11px;
    font-weight: 600;
}

.search-results-heading strong {
    color: #0f172a;

    font-weight: 800;
}


/* =========================================================
   RESULT LIST
   ========================================================= */

.search-results-list {
    display: flex;
    flex-direction: column;

    gap: 8px;
}


/* =========================================================
   RESULT ITEM
   ========================================================= */

.search-result-item {
    display: flex;
    align-items: center;

    gap: 13px;

    width: 100%;

    padding: 10px;

    border: 1px solid rgba(15, 23, 42, .08);
    border-radius: 14px;

    background: #ffffff;

    text-decoration: none;

    transition:
        border-color .2s ease,
        box-shadow .2s ease,
        transform .2s ease;
}

.search-result-item:hover {
    border-color: rgba(37, 99, 235, .25);

    box-shadow:
        0 8px 22px rgba(2, 6, 23, .07);

    transform: translateY(-1px);
}


/* =========================================================
   RESULT IMAGE
   ========================================================= */

.search-result-image {
    width: 62px;
    height: 62px;

    flex: 0 0 62px;

    overflow: hidden;

    border-radius: 11px;

    background: #f8fafc;
}

.search-result-image img {
    width: 100%;
    height: 100%;

    display: block;

    object-fit: cover;
}


/* =========================================================
   RESULT CONTENT
   ========================================================= */

.search-result-content {
    flex: 1;

    min-width: 0;
}

.search-result-content strong {
    display: block;

    margin-bottom: 3px;

    color: #0f172a;

    font-size: 13px;
    line-height: 1.4;

    font-weight: 800;
}

.search-result-content small {
    display: block;

    color: #64748b;

    font-size: 10px;
    line-height: 1.5;
}


/* =========================================================
   RESULT ARROW
   ========================================================= */

.search-result-arrow {
    width: 30px;
    height: 30px;

    flex: 0 0 30px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 9px;

    background: #eff6ff;

    color: #2563eb;

    font-size: 16px;
    font-weight: 700;
}


/* =========================================================
   NO RESULT
   ========================================================= */

.search-no-result {
    padding: 20px;

    border-radius: 13px;

    background: #f8fafc;

    text-align: center;
}

.search-no-result strong {
    display: block;

    margin-bottom: 4px;

    color: #0f172a;

    font-size: 13px;
}

.search-no-result span {
    color: #64748b;

    font-size: 11px;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 600px) {

    .search-modal-card {
        width: calc(100% - 24px);

        margin: 5vh auto 0;

        padding: 18px;

        border-radius: 18px;
    }


    .search-modal-title {
        font-size: 17px;
    }


    .search-modal-form {
        flex-direction: column;

        align-items: stretch;
    }


    .search-modal-input {
        width: 100%;

        height: 46px;
    }


    .search-modal-submit {
        width: 100%;

        height: 46px;
    }


    .search-result-image {
        width: 55px;
        height: 55px;

        flex-basis: 55px;
    }


    .search-result-content strong {
        font-size: 12px;
    }


    .search-result-arrow {
        width: 28px;
        height: 28px;

        flex-basis: 28px;
    }

}