/* 404 hero live article-search dropdown — modern, variable-driven UI. */
.elementor-widget-aliclick_contact_hero .ac404-live-search {
    position: relative;
    z-index: 40;
    width: 100%;
    margin-bottom: 22px;
}

.elementor-widget-aliclick_contact_hero .ac404-live-search > .ac404-hero__search {
    margin-bottom: 0;
}

.ac404-live-search__panel[hidden] {
    display: none !important;
}

.ac404-live-search__panel {
    position: absolute;
    z-index: 999;
    inset-inline-start: 50%;
    top: calc(100% + var(--ac404-live-panel-offset, 10px));
    width: min(var(--ac404-live-panel-width, 100%), calc(100vw - 24px));
    max-height: min(var(--ac404-live-panel-max-height, 460px), 72vh);
    overflow-x: hidden;
    overflow-y: auto;
    box-sizing: border-box;
    padding: 10px;
    border: var(--ac404-live-panel-border-width, 1px) solid var(--ac404-live-panel-border, #dce7f5);
    border-radius: var(--ac404-live-panel-radius, 18px);
    background: color-mix(in srgb, var(--ac404-live-panel-bg, #fff) 97%, transparent);
    box-shadow: 0 22px 58px rgba(28, 61, 110, .16);
    backdrop-filter: blur(16px) saturate(125%);
    transform: translateX(-50%);
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: #c9d8ec transparent;
    animation: ac404-live-panel-in .16s ease-out both;
}

.ac404-live-search__panel.is-drop-up {
    top: auto;
    bottom: calc(100% + var(--ac404-live-panel-offset, 10px));
    transform-origin: bottom center;
}

.ac404-live-search__panel::-webkit-scrollbar {
    width: 7px;
}

.ac404-live-search__panel::-webkit-scrollbar-track {
    background: transparent;
}

.ac404-live-search__panel::-webkit-scrollbar-thumb {
    border: 2px solid transparent;
    border-radius: 999px;
    background: #c9d8ec;
    background-clip: padding-box;
}

.ac404-live-search__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 5px 6px 10px;
    color: var(--ac404-live-state-text, #65738b);
    font-size: 12px;
    font-weight: 800;
    line-height: 1.4;
}

.ac404-live-search__header-label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.ac404-live-search__header-label::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #1769e0;
    box-shadow: 0 0 0 4px rgba(23, 105, 224, .09);
}

.ac404-live-search__count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
    padding-inline: 8px;
    border-radius: 999px;
    color: #1769e0;
    background: #eaf3ff;
    font-size: 11px;
    font-weight: 850;
}

.ac404-live-search__list {
    display: grid;
    gap: var(--ac404-live-item-list-gap, 7px);
}

.ac404-live-search__item {
    position: relative;
    display: grid;
    grid-template-columns: var(--ac404-live-thumb-size, 64px) minmax(0, 1fr) 28px;
    align-items: center;
    gap: var(--ac404-live-content-gap, 12px);
    min-height: calc(var(--ac404-live-thumb-size, 64px) + 20px);
    padding: 10px;
    overflow: hidden;
    border: 1px solid transparent;
    border-radius: var(--ac404-live-item-radius, 14px);
    color: inherit;
    background: var(--ac404-live-item-bg, #fff);
    text-decoration: none !important;
    box-shadow: 0 2px 0 rgba(31, 65, 113, .025);
    transition: background .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.ac404-live-search__item::after {
    content: "";
    position: absolute;
    inset-inline: 10px;
    bottom: -1px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(212, 224, 240, .72), transparent);
    opacity: .55;
}

.ac404-live-search__item:last-child::after {
    display: none;
}

.ac404-live-search__item.is-no-thumb {
    grid-template-columns: minmax(0, 1fr) 28px;
}

.ac404-live-search__item:hover,
.ac404-live-search__item:focus-visible,
.ac404-live-search__item.is-active {
    outline: none;
    border-color: var(--ac404-live-item-hover-border, #cfe0f8);
    background: var(--ac404-live-item-hover-bg, #f2f7ff);
    box-shadow: 0 9px 24px rgba(29, 76, 141, .08);
    transform: translateY(-1px);
}

.ac404-live-search__thumb {
    display: block;
    width: var(--ac404-live-thumb-size, 64px);
    height: var(--ac404-live-thumb-size, 64px);
    object-fit: cover;
    border: 1px solid rgba(218, 229, 244, .82);
    border-radius: var(--ac404-live-thumb-radius, 12px);
    background: #eef4fc;
    box-shadow: 0 5px 14px rgba(31, 71, 129, .07);
}

.ac404-live-search__thumb--empty {
    position: relative;
    background: linear-gradient(145deg, #f0f6ff, #e5effc);
}

.ac404-live-search__thumb--empty::before,
.ac404-live-search__thumb--empty::after {
    content: "";
    position: absolute;
    inset: 50% auto auto 50%;
    transform: translate(-50%, -50%);
}

.ac404-live-search__thumb--empty::before {
    width: 23px;
    height: 18px;
    border: 2px solid #7fa9e8;
    border-radius: 5px;
}

.ac404-live-search__thumb--empty::after {
    width: 8px;
    height: 8px;
    margin: -4px 0 0 5px;
    border-radius: 50%;
    background: #7fa9e8;
}

.ac404-live-search__body {
    display: grid;
    min-width: 0;
    gap: 5px;
}

.ac404-live-search__topline {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 7px;
    min-width: 0;
}

.ac404-live-search__category {
    display: inline-flex;
    align-items: center;
    width: max-content;
    max-width: 100%;
    padding: 3px 8px;
    overflow: hidden;
    border-radius: var(--ac404-live-category-radius, 999px);
    color: var(--ac404-live-category-color, #1769e0);
    background: var(--ac404-live-category-bg, #eaf3ff);
    font-size: 9.5px;
    font-weight: 800;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ac404-live-search__title {
    display: block;
    overflow: hidden;
    color: var(--ac404-live-title-color, #172033);
    font-size: 13.5px;
    font-weight: 850;
    line-height: 1.55;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ac404-live-search__excerpt {
    display: -webkit-box;
    overflow: hidden;
    color: var(--ac404-live-excerpt-color, #68768b);
    font-size: 11.5px;
    line-height: 1.65;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.ac404-live-search__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    color: var(--ac404-live-meta-color, #8b99ad);
    font-size: 10.5px;
    line-height: 1.45;
}

.ac404-live-search__meta-part {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.ac404-live-search__meta-part + .ac404-live-search__meta-part::before {
    content: "";
    width: 3px;
    height: 3px;
    margin-inline-end: 2px;
    border-radius: 50%;
    background: currentColor;
    opacity: .55;
}

.ac404-live-search__match {
    padding: 0 .08em;
    border-radius: 4px;
    color: var(--ac404-live-highlight-color, #0c4fbd);
    background: var(--ac404-live-highlight-bg, #fff2b8);
    font: inherit;
}

.ac404-live-search__arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 9px;
    color: #1769e0;
    background: rgba(23, 105, 224, .07);
    font-size: 20px;
    font-weight: 700;
    line-height: 1;
    transition: color .18s ease, background .18s ease, transform .18s ease;
}

.ac404-live-search__item:hover .ac404-live-search__arrow,
.ac404-live-search__item:focus-visible .ac404-live-search__arrow,
.ac404-live-search__item.is-active .ac404-live-search__arrow {
    color: #fff;
    background: #1769e0;
    transform: translateX(-2px);
}

[dir="ltr"] .ac404-live-search__arrow {
    transform: rotate(180deg);
}

[dir="ltr"] .ac404-live-search__item:hover .ac404-live-search__arrow,
[dir="ltr"] .ac404-live-search__item:focus-visible .ac404-live-search__arrow,
[dir="ltr"] .ac404-live-search__item.is-active .ac404-live-search__arrow {
    transform: rotate(180deg) translateX(-2px);
}

/* Loading skeleton. */
.ac404-live-search__skeleton {
    display: grid;
    gap: var(--ac404-live-item-list-gap, 7px);
    padding-block: 2px;
}

.ac404-live-search__skeleton-row {
    display: grid;
    grid-template-columns: var(--ac404-live-thumb-size, 64px) minmax(0, 1fr);
    align-items: center;
    gap: var(--ac404-live-content-gap, 12px);
    padding: 10px;
    border-radius: var(--ac404-live-item-radius, 14px);
    background: rgba(248, 251, 255, .72);
}

.ac404-live-search__skeleton-thumb,
.ac404-live-search__skeleton-line {
    position: relative;
    overflow: hidden;
    background: var(--ac404-live-skeleton-base, #edf2f8);
}

.ac404-live-search__skeleton-thumb::after,
.ac404-live-search__skeleton-line::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, transparent 20%, var(--ac404-live-skeleton-shine, #f8fbff) 48%, transparent 76%);
    transform: translateX(-105%);
    animation: ac404-skeleton-shine 1.15s ease-in-out infinite;
}

.ac404-live-search__skeleton-thumb {
    width: var(--ac404-live-thumb-size, 64px);
    height: var(--ac404-live-thumb-size, 64px);
    border-radius: var(--ac404-live-thumb-radius, 12px);
}

.ac404-live-search__skeleton-copy {
    display: grid;
    gap: 8px;
}

.ac404-live-search__skeleton-line {
    height: 9px;
    border-radius: 999px;
}

.ac404-live-search__skeleton-line:first-child {
    width: 72%;
    height: 12px;
}

.ac404-live-search__skeleton-line:nth-child(2) {
    width: 93%;
}

.ac404-live-search__skeleton-line:nth-child(3) {
    width: 47%;
}

/* Empty and error states. */
.ac404-live-search__state {
    display: grid;
    justify-items: center;
    gap: 8px;
    padding: 24px 16px 22px;
    color: var(--ac404-live-state-text, #65738b);
    text-align: center;
}

.ac404-live-search__state-icon {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    margin-bottom: 2px;
    border-radius: 15px;
    color: #1769e0;
    background: #edf5ff;
    font-size: 21px;
    font-weight: 800;
}

.ac404-live-search__state-title {
    color: var(--ac404-live-title-color, #172033);
    font-size: 13.5px;
    font-weight: 850;
    line-height: 1.5;
}

.ac404-live-search__state-subtitle {
    max-width: 340px;
    color: var(--ac404-live-state-text, #65738b);
    font-size: 11.5px;
    line-height: 1.7;
}

.ac404-live-search__state.is-error .ac404-live-search__state-icon {
    color: #b75b2d;
    background: #fff3ec;
}

/* Footer action. */
.ac404-live-search__footer {
    display: flex;
    justify-content: var(--ac404-live-footer-align, center);
    padding: 9px 2px 2px;
}

.ac404-live-search__all {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: min(240px, 100%);
    min-height: 42px;
    padding: 9px 18px;
    border: 1px solid transparent;
    border-radius: var(--ac404-live-footer-radius, 12px);
    color: var(--ac404-live-footer-color, #1769e0);
    background: var(--ac404-live-footer-bg, #edf5ff);
    box-shadow: none;
    font: inherit;
    font-size: 12px;
    font-weight: 850;
    cursor: pointer;
    transition: color .18s ease, background .18s ease, border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}

.ac404-live-search__all:hover,
.ac404-live-search__all:focus-visible {
    outline: none;
    color: var(--ac404-live-footer-hover-color, #fff);
    background: var(--ac404-live-footer-hover-bg, #1769e0);
    box-shadow: 0 9px 22px rgba(23, 105, 224, .18);
    transform: translateY(-1px);
}

@keyframes ac404-live-panel-in {
    from { opacity: 0; transform: translate(-50%, -4px) scale(.99); }
    to { opacity: 1; transform: translate(-50%, 0) scale(1); }
}

@keyframes ac404-skeleton-shine {
    to { transform: translateX(105%); }
}

@media (prefers-reduced-motion: reduce) {
    .ac404-live-search__panel,
    .ac404-live-search__item,
    .ac404-live-search__arrow,
    .ac404-live-search__all,
    .ac404-live-search__skeleton-thumb::after,
    .ac404-live-search__skeleton-line::after {
        animation: none !important;
        transition: none !important;
    }
}

@media (max-width: 767px) {
    .ac404-live-search__panel {
        width: min(var(--ac404-live-panel-width, 100%), calc(100vw - 18px));
        max-height: min(var(--ac404-live-panel-max-height, 420px), 62vh);
    }

    .ac404-live-search__item {
        grid-template-columns: var(--ac404-live-thumb-size, 52px) minmax(0, 1fr) 25px;
        min-height: calc(var(--ac404-live-thumb-size, 52px) + 18px);
    }

    .ac404-live-search__item.is-no-thumb {
        grid-template-columns: minmax(0, 1fr) 25px;
    }

    .ac404-live-search__excerpt {
        -webkit-line-clamp: 1;
    }

    .ac404-live-search__arrow {
        width: 25px;
        height: 25px;
        border-radius: 8px;
        font-size: 18px;
    }

    .ac404-live-search__skeleton-row {
        grid-template-columns: var(--ac404-live-thumb-size, 52px) minmax(0, 1fr);
    }
}
