html.nova-search-open,
body.nova-search-open {
    overflow: hidden !important;
}

.nova-search-trigger {
    display: inline-grid;
    place-items: center;
    width: 42px;
    height: 42px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: currentColor;
    cursor: pointer;
}

.nova-search-trigger:hover {
    background: rgba(255,255,255,.10);
}

.nova-search-trigger svg,
.nova-search-field-icon svg,
.nova-search-close svg {
    width: 25px;
    height: 25px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.9;
    stroke-linecap: round;
}

.nova-search-header-item {
    display: flex;
    align-items: center;
}

.nova-search-modal {
    position: fixed;
    inset: 0;
    z-index: 2147482000;
    padding: 18px;
    opacity: 0;
    transition: opacity .16s ease;
}

.nova-search-modal.is-open {
    opacity: 1;
}

.nova-search-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(4,19,43,.76);
    backdrop-filter: blur(5px);
}

.nova-search-panel {
    position: relative;
    width: min(100%, 1320px);
    max-height: calc(100dvh - 36px);
    margin: 0 auto;
    overflow: hidden;
    border-radius: 28px;
    background: #fff;
    box-shadow: 0 30px 90px rgba(0,0,0,.24);
    transform: translateY(12px) scale(.99);
    transition: transform .18s ease;
}

.nova-search-modal.is-open .nova-search-panel {
    transform: translateY(0) scale(1);
}

.nova-search-topbar {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 16px;
    min-height: 108px;
    padding: 0 34px;
    border-bottom: 1px solid #e6edf5;
}

.nova-search-field-icon {
    display: grid;
    place-items: center;
    color: #91a4bb;
}

.nova-search-input {
    width: 100%;
    height: 72px;
    padding: 0;
    border: 0 !important;
    outline: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #14233a;
    font-size: clamp(23px, 2vw, 34px);
    font-weight: 400;
}

.nova-search-input::placeholder {
    color: #91a4bb;
    opacity: 1;
}

.nova-search-close {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #91a4bb;
    cursor: pointer;
}

.nova-search-close:hover {
    background: #f1f5f9;
    color: #284565;
}

.nova-search-body {
    max-height: calc(100dvh - 145px);
    overflow-y: auto;
    padding: 38px 40px 44px;
}

.nova-search-body h3 {
    margin: 0 0 20px;
    color: #0f1d33;
    font-size: 24px;
    line-height: 1.2;
}

.nova-search-body h3 span {
    color: #285ea8;
}

.nova-search-trending {
    margin-bottom: 38px;
}

.nova-search-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.nova-search-chip {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 50px;
    padding: 0 20px;
    border: 0;
    border-radius: 999px;
    background: #f2f6fa;
    color: #31445f;
    font: inherit;
    font-size: 18px;
    cursor: pointer;
}

.nova-search-chip:hover {
    background: #e7eff7;
}

.nova-search-status {
    min-height: 24px;
    margin: -8px 0 18px;
    color: #6e8199;
    font-size: 14px;
}

.nova-search-results {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
}

.nova-search-card {
    overflow: hidden;
    border: 1px solid #d9e3ee;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 8px 24px rgba(22,52,88,.08);
}

.nova-search-card-image {
    display: block;
    aspect-ratio: 1 / 1.1;
    overflow: hidden;
    background: #eef4fa;
}

.nova-search-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .22s ease;
}

.nova-search-card:hover .nova-search-card-image img {
    transform: scale(1.025);
}

.nova-search-card-content {
    padding: 20px;
}

.nova-search-card h4 {
    margin: 0 0 8px;
    font-size: 21px;
    line-height: 1.2;
}

.nova-search-card h4 a {
    color: #111c31;
}

.nova-search-card-price {
    margin-bottom: 6px;
    color: #111c31;
    font-size: 20px;
    font-weight: 700;
}

.nova-search-card-sku {
    margin-bottom: 12px;
    color: #7b8da3;
    font-size: 12px;
}

.nova-search-card-button {
    display: grid;
    place-items: center;
    min-height: 48px;
    margin-top: 16px;
    border-radius: 999px;
    background: #111;
    color: #fff !important;
    font-weight: 700;
    text-decoration: none !important;
}

.nova-search-card-button:hover {
    background: #17375f;
}

@media (max-width: 1100px) {
    .nova-search-results {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 820px) {
    .nova-search-results {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .nova-search-panel {
        border-radius: 22px;
    }
}

@media (max-width: 560px) {
    .nova-search-modal {
        padding: 8px;
    }

    .nova-search-panel {
        max-height: calc(100dvh - 16px);
        border-radius: 18px;
    }

    .nova-search-topbar {
        min-height: 74px;
        gap: 10px;
        padding: 0 16px;
    }

    .nova-search-input {
        height: 58px;
        font-size: 20px;
    }

    .nova-search-field-icon svg {
        width: 22px;
        height: 22px;
    }

    .nova-search-close {
        width: 38px;
        height: 38px;
    }

    .nova-search-body {
        max-height: calc(100dvh - 92px);
        padding: 24px 16px 30px;
    }

    .nova-search-body h3 {
        font-size: 20px;
    }

    .nova-search-chip {
        min-height: 42px;
        padding: 0 16px;
        font-size: 15px;
    }

    .nova-search-results {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .nova-search-card {
        display: grid;
        grid-template-columns: 118px 1fr;
        border-radius: 17px;
    }

    .nova-search-card-image {
        aspect-ratio: auto;
        min-height: 150px;
    }

    .nova-search-card-content {
        padding: 16px;
    }

    .nova-search-card h4 {
        font-size: 18px;
    }

    .nova-search-card-price {
        font-size: 17px;
    }

    .nova-search-card-button {
        min-height: 42px;
        font-size: 14px;
    }
}


/* v3.2.3 compact search layout */
.nova-search-panel {
    width: min(100%, 980px);
    max-height: min(82dvh, 760px);
    border-radius: 22px;
}

.nova-search-topbar {
    min-height: 78px;
    padding: 0 24px;
}

.nova-search-input {
    height: 58px;
    font-size: clamp(19px, 1.7vw, 26px);
}

.nova-search-body {
    max-height: calc(min(82dvh, 760px) - 78px);
    padding: 26px 28px 30px;
}

.nova-search-trending {
    margin-bottom: 26px;
}

.nova-search-body h3 {
    margin-bottom: 14px;
    font-size: 20px;
}

.nova-search-chip {
    min-height: 40px;
    padding: 0 16px;
    font-size: 14px;
}

.nova-search-results {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.nova-search-card {
    border-radius: 16px;
}

.nova-search-card-image {
    aspect-ratio: 1 / .92;
}

.nova-search-card-content {
    padding: 14px;
}

.nova-search-card h4 {
    margin-bottom: 5px;
    font-size: 16px;
}

.nova-search-card-price {
    font-size: 16px;
}

.nova-search-card-sku {
    margin-bottom: 8px;
    font-size: 10px;
}

.nova-search-card-button {
    min-height: 40px;
    margin-top: 10px;
    font-size: 13px;
}

@media (max-width: 900px) {
    .nova-search-panel {
        width: min(100%, 760px);
    }

    .nova-search-results {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 680px) {
    .nova-search-modal {
        padding: 6px;
    }

    .nova-search-panel {
        width: 100%;
        max-height: calc(100dvh - 12px);
        border-radius: 16px;
    }

    .nova-search-topbar {
        min-height: 64px;
        padding: 0 14px;
    }

    .nova-search-body {
        max-height: calc(100dvh - 76px);
        padding: 18px 14px 24px;
    }

    .nova-search-trending {
        margin-bottom: 20px;
    }

    .nova-search-chips {
        gap: 8px;
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 4px;
        scrollbar-width: thin;
    }

    .nova-search-chip {
        flex: 0 0 auto;
        min-height: 38px;
        font-size: 13px;
    }

    .nova-search-results {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .nova-search-card {
        display: block;
    }

    .nova-search-card-image {
        aspect-ratio: 1 / .88;
        min-height: 0;
    }

    .nova-search-card-content {
        padding: 11px;
    }

    .nova-search-card h4 {
        font-size: 14px;
    }

    .nova-search-card-price {
        font-size: 14px;
    }

    .nova-search-card-button {
        min-height: 38px;
        font-size: 12px;
    }
}


/* v3.2.4 search accuracy states */
.nova-search-chip.is-active {
    background: #ffffff;
    box-shadow: inset 0 0 0 2px #294565;
    color: #1a3555;
}

.nova-search-status:not(:empty) {
    padding: 8px 0 12px;
}


/* v3.3.1 — improved mobile search experience */
@media (max-width: 680px) {
    .nova-search-modal {
        padding: 0;
    }

    .nova-search-panel {
        width: 100%;
        height: 100dvh;
        max-height: 100dvh;
        border-radius: 0;
    }

    .nova-search-topbar {
        position: sticky;
        top: 0;
        z-index: 4;
        min-height: 64px;
        padding: 0 12px;
        background: #fff;
    }

    .nova-search-field-icon {
        display: none;
    }

    .nova-search-topbar {
        grid-template-columns: 1fr auto;
        gap: 8px;
    }

    .nova-search-input {
        min-width: 0;
        height: 58px;
        font-size: 18px;
        line-height: 1.2;
        text-overflow: ellipsis;
    }

    .nova-search-close {
        flex: 0 0 auto;
        width: 40px;
        height: 40px;
    }

    .nova-search-body {
        max-height: calc(100dvh - 64px);
        padding: 18px 14px 28px;
    }

    .nova-search-body h3 {
        margin-bottom: 12px;
        font-size: 18px;
    }

    .nova-search-trending {
        margin-bottom: 22px;
    }

    .nova-search-chips {
        display: grid;
        grid-auto-flow: column;
        grid-auto-columns: max-content;
        gap: 8px;
        overflow-x: auto;
        padding: 2px 2px 8px;
        scroll-snap-type: x proximity;
        -webkit-overflow-scrolling: touch;
    }

    .nova-search-chip {
        min-height: 38px;
        padding: 0 14px;
        font-size: 13px;
        scroll-snap-align: start;
    }

    .nova-search-status {
        margin-bottom: 10px;
        font-size: 13px;
    }

    .nova-search-results {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .nova-search-card {
        display: grid;
        grid-template-columns: 112px minmax(0, 1fr);
        min-height: 152px;
        overflow: hidden;
        border-radius: 16px;
    }

    .nova-search-card-image {
        height: 100%;
        min-height: 152px;
        aspect-ratio: auto;
    }

    .nova-search-card-image img {
        object-fit: cover;
    }

    .nova-search-card-content {
        display: flex;
        flex-direction: column;
        min-width: 0;
        padding: 14px;
    }

    .nova-search-card h4 {
        margin-bottom: 6px;
        font-size: 16px;
        line-height: 1.25;
    }

    .nova-search-card h4 a {
        display: -webkit-box;
        overflow: hidden;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
    }

    .nova-search-card-price {
        margin-bottom: 4px;
        font-size: 15px;
    }

    .nova-search-card-sku {
        display: none;
    }

    .nova-search-card-button {
        min-height: 40px;
        margin-top: auto;
        font-size: 13px;
    }
}

@media (max-width: 390px) {
    .nova-search-body {
        padding-left: 10px;
        padding-right: 10px;
    }

    .nova-search-card {
        grid-template-columns: 100px minmax(0, 1fr);
    }

    .nova-search-card-image {
        min-height: 144px;
    }

    .nova-search-card-content {
        padding: 12px;
    }

    .nova-search-card h4 {
        font-size: 15px;
    }

    .nova-search-card-price {
        font-size: 14px;
    }

    .nova-search-card-button {
        min-height: 38px;
        font-size: 12px;
    }
}


/* v3.4.0 instant catalog search */
.nova-search-results {
    content-visibility: auto;
    contain-intrinsic-size: 400px;
}
