/* ArtGallery Unified Discovery Search v1.0.49
   Adapter for the new #ag-new-hero homepage design. */

#ag-new-hero.aguds-hero-enabled .aguds-hero-shell {
    position: relative !important;
    overflow: visible !important;
    z-index: 40 !important;
}

#ag-new-hero.aguds-hero-enabled .ag-search-panel {
    position: relative;
    z-index: 42;
}

#ag-new-hero.aguds-hero-enabled .ag-filter,
#ag-new-hero.aguds-hero-enabled .ag-discovery,
#ag-new-hero.aguds-hero-enabled .ag-search-tab {
    touch-action: manipulation;
}

#ag-new-hero .aguds-hero-popover,
#ag-new-hero .aguds-hero-results {
    position: absolute;
    z-index: 200;
    box-sizing: border-box;
    color: #17212a;
    background: #fff;
    border: 1px solid rgba(219,142,1,.48);
    border-radius: 10px;
    box-shadow: 0 22px 54px rgba(0,0,0,.34);
    overflow: hidden;
}

#ag-new-hero .aguds-hero-popover[hidden],
#ag-new-hero .aguds-hero-results[hidden] {
    display: none !important;
}

#ag-new-hero .aguds-hero-popover {
    max-height: 360px;
}

#ag-new-hero .aguds-hero-popover-list {
    max-height: 292px;
    overflow: auto;
    padding: 7px;
    scrollbar-width: thin;
}

#ag-new-hero .aguds-hero-option,
#ag-new-hero .aguds-hero-radio {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: 40px;
    margin: 0;
    padding: 8px 10px;
    color: #17212a;
    background: transparent;
    border: 0;
    border-radius: 7px;
    font: inherit;
    font-size: 12px;
    font-weight: 650;
    text-align: left;
    cursor: pointer;
    transition: background .18s ease, color .18s ease;
}

#ag-new-hero .aguds-hero-option:hover,
#ag-new-hero .aguds-hero-radio:hover,
#ag-new-hero .aguds-hero-radio.is-selected {
    background: rgba(219,142,1,.10);
}

#ag-new-hero .aguds-hero-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

#ag-new-hero .aguds-hero-check {
    position: relative;
    width: 17px;
    height: 17px;
    flex: 0 0 17px;
    border: 1.5px solid #b2b9bf;
    border-radius: 4px;
    background: #fff;
}

#ag-new-hero .aguds-hero-option input:checked + .aguds-hero-check {
    border-color: #DB8E01;
    background: #DB8E01;
}

#ag-new-hero .aguds-hero-option input:checked + .aguds-hero-check::after {
    content: "";
    position: absolute;
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

#ag-new-hero .aguds-hero-option-name {
    min-width: 0;
    flex: 1;
}

#ag-new-hero .aguds-hero-option-count {
    margin-left: auto;
    color: #8a9298;
    font-size: 10px;
    font-weight: 700;
}

#ag-new-hero .aguds-hero-popover-actions {
    display: flex;
    gap: 8px;
    padding: 9px;
    border-top: 1px solid #eceff1;
    background: #fafafa;
}

#ag-new-hero .aguds-hero-popover-actions button {
    min-height: 36px;
    flex: 1;
    margin: 0;
    padding: 0 12px;
    border-radius: 6px;
    font: inherit;
    font-size: 10px;
    font-weight: 800;
    cursor: pointer;
}

#ag-new-hero .aguds-hero-reset {
    color: #17212a;
    background: #fff;
    border: 1px solid #d9dde0;
}

#ag-new-hero .aguds-hero-apply {
    color: #111820;
    background: linear-gradient(180deg,#ffc64f,#DB8E01);
    border: 1px solid #DB8E01;
}

#ag-new-hero .aguds-hero-radio {
    justify-content: space-between;
}

#ag-new-hero .aguds-hero-radio.is-selected {
    color: #9b6100;
    font-weight: 800;
}

#ag-new-hero .aguds-hero-results {
    max-height: 430px;
    overflow: auto;
    padding: 8px;
}

#ag-new-hero .aguds-hero-results-heading {
    padding: 8px 10px 7px;
    color: #9b6100;
    font-size: 10px;
    font-weight: 850;
    letter-spacing: .12em;
    text-transform: uppercase;
}

#ag-new-hero .aguds-hero-result-row,
#ag-new-hero .aguds-hero-space-payload .listing-item .content-inner {
    position: relative;
    display: flex !important;
    align-items: center !important;
    gap: 11px !important;
    min-height: 58px !important;
    margin: 0 !important;
    padding: 8px 10px !important;
    color: #17212a !important;
    text-decoration: none !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 8px !important;
    box-shadow: none !important;
    transition: background .18s ease !important;
}

#ag-new-hero .aguds-hero-result-row:hover,
#ag-new-hero .aguds-hero-space-payload .listing-item .content-inner:hover {
    background: rgba(219,142,1,.08) !important;
}

#ag-new-hero .aguds-hero-result-avatar,
#ag-new-hero .aguds-hero-space-payload .listing-item .lt-logo {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 43px !important;
    height: 43px !important;
    flex: 0 0 43px !important;
    overflow: hidden !important;
    border: 1px solid rgba(219,142,1,.38) !important;
    border-radius: 50% !important;
    background: #f2f4f5 !important;
}

#ag-new-hero .aguds-hero-result-avatar img,
#ag-new-hero .aguds-hero-space-payload .listing-item .lt-logo img {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    border-radius: 50% !important;
}

#ag-new-hero .aguds-hero-avatar-fallback {
    width: 16px;
    height: 16px;
    border: 2px solid #aeb6bc;
    border-radius: 50%;
}

#ag-new-hero .aguds-hero-result-copy,
#ag-new-hero .aguds-hero-space-payload .listing-item .lt-info {
    display: flex !important;
    min-width: 0 !important;
    flex: 1 !important;
    flex-direction: column !important;
    justify-content: center !important;
}

#ag-new-hero .aguds-hero-result-copy strong,
#ag-new-hero .aguds-hero-space-payload .listing-item .title {
    margin: 0 0 3px !important;
    color: #17212a !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    line-height: 1.2 !important;
}

#ag-new-hero .aguds-hero-result-copy small,
#ag-new-hero .aguds-hero-space-payload .listing-item .address {
    margin: 0 !important;
    color: #737c84 !important;
    font-size: 10px !important;
    font-weight: 600 !important;
    line-height: 1.25 !important;
}

#ag-new-hero .aguds-hero-result-arrow {
    margin-left: auto;
    color: #DB8E01;
    font-size: 24px;
    line-height: 1;
}

#ag-new-hero .aguds-hero-view-all {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 5px;
    padding: 10px 12px;
    color: #fff !important;
    background: #17212a;
    border-radius: 7px;
    font-size: 10px;
    font-weight: 800;
    text-decoration: none !important;
}

#ag-new-hero .aguds-hero-loading,
#ag-new-hero .aguds-hero-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 62px;
    color: #626b72;
    font-size: 11px;
    font-weight: 700;
}

#ag-new-hero .aguds-hero-loading > span {
    width: 16px;
    height: 16px;
    border: 2px solid #e0e3e5;
    border-top-color: #DB8E01;
    border-radius: 50%;
    animation: agudsHeroSpin .75s linear infinite;
}

@keyframes agudsHeroSpin {
    to { transform: rotate(360deg); }
}

#ag-new-hero .aguds-hero-space-payload .keyword_list_autocomplete,
#ag-new-hero .aguds-hero-space-payload .listing-item {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

#ag-new-hero .aguds-hero-space-payload .listing-item .overlay {
    position: absolute !important;
    inset: 0 !important;
    z-index: 3 !important;
}

@media (max-width: 1024px) {
    #ag-new-hero .aguds-hero-popover,
    #ag-new-hero .aguds-hero-results {
        max-width: calc(100vw - 32px);
    }
}

@media (max-width: 767px) {
    #ag-new-hero .aguds-hero-popover {
        left: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    #ag-new-hero .aguds-hero-results {
        max-height: 360px;
    }
}

/* =========================================================
   v1.0.48 — PREMIUM #161C26 SEARCH PALETTE

   These selectors intentionally have higher specificity than
   page-level HTML widget CSS. This lets the plugin own the
   search component palette while Elementor continues to own
   positioning / spacing around the component.
   ========================================================= */

html body #ag-new-hero.aguds-hero-enabled {
    --aguds-surface: #161C26;
    --aguds-surface-hover: #1D2632;
    --aguds-surface-active: #202B38;
    --aguds-accent: #FFB300;
}

/* Outer search row / panel */
html body #ag-new-hero.aguds-hero-enabled .ag-search-panel {
    background: rgba(22,28,38,.94) !important;
    border-color: rgba(255,179,0,.34) !important;
    box-shadow:
        0 14px 32px rgba(0,0,0,.16),
        inset 0 1px 0 rgba(255,255,255,.035) !important;
}

/* Artists / Art Spaces tabs */
html body #ag-new-hero.aguds-hero-enabled .ag-search-tab {
    background: var(--aguds-surface) !important;
    border-color: rgba(255,255,255,.13) !important;
    color: rgba(255,255,255,.66) !important;
}

html body #ag-new-hero.aguds-hero-enabled .ag-search-tab:hover {
    background: var(--aguds-surface-hover) !important;
    border-color: rgba(255,179,0,.42) !important;
    color: #fff !important;
}

html body #ag-new-hero.aguds-hero-enabled .ag-search-tab.is-active {
    background: var(--aguds-surface-active) !important;
    border-color: rgba(255,179,0,.72) !important;
    color: var(--aguds-accent) !important;
}

html body #ag-new-hero.aguds-hero-enabled .ag-search-tab.is-active::after {
    background: linear-gradient(
        90deg,
        rgba(255,179,0,.55),
        #FFB300,
        rgba(255,179,0,.55)
    ) !important;
}

/* Name search field */
html body #ag-new-hero.aguds-hero-enabled .ag-search-field {
    background: var(--aguds-surface) !important;
    border-color: rgba(255,255,255,.14) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.025) !important;
}

html body #ag-new-hero.aguds-hero-enabled .ag-search-field:hover {
    background: var(--aguds-surface-hover) !important;
    border-color: rgba(255,179,0,.34) !important;
}

html body #ag-new-hero.aguds-hero-enabled .ag-search-field:focus-within {
    background: var(--aguds-surface-active) !important;
    border-color: rgba(255,179,0,.66) !important;
    box-shadow: 0 0 0 2px rgba(255,179,0,.055) !important;
}

/* Discipline / Country / All Categories */
html body #ag-new-hero.aguds-hero-enabled .ag-filter {
    background: var(--aguds-surface) !important;
    border-color: rgba(255,255,255,.14) !important;
    color: rgba(255,255,255,.92) !important;
    -webkit-text-fill-color: rgba(255,255,255,.92) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.025) !important;
}

html body #ag-new-hero.aguds-hero-enabled .ag-filter:hover {
    background: var(--aguds-surface-hover) !important;
    border-color: rgba(255,179,0,.40) !important;
    color: #fff !important;
    -webkit-text-fill-color: #fff !important;
}

html body #ag-new-hero.aguds-hero-enabled .ag-filter:focus,
html body #ag-new-hero.aguds-hero-enabled .ag-filter:active {
    background: var(--aguds-surface-active) !important;
    border-color: rgba(255,179,0,.66) !important;
    color: #fff !important;
    -webkit-text-fill-color: #fff !important;
    box-shadow: 0 0 0 2px rgba(255,179,0,.055) !important;
}

/* Keep autocomplete panels white for maximum legibility on the dark hero. */
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-results {
    background: #fff !important;
    border-color: rgba(255,179,0,.55) !important;
}

/* Results width/left are set in hero-adapter.js from the live
   .ag-search-field geometry. Do not stretch them to the shell. */
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-results {
    min-width: 0 !important;
}

/* Mobile search fields are already full width, so the JS geometry
   naturally gives a full-width result list without a special override. */
@media (max-width: 767px) {
    html body #ag-new-hero.aguds-hero-enabled .aguds-hero-results {
        max-width: calc(100vw - 24px) !important;
    }
}



/* =========================================================
   v1.0.49 — READABILITY REFINEMENT

   Slightly larger typed search text and slightly larger
   autocomplete identity elements on both Artists and Art Spaces.
   Result list geometry from v1.0.48 is intentionally unchanged:
   the list remains exactly as wide as the active name input.
   ========================================================= */

/* Typed search text: one visual step larger. */
html body #ag-new-hero.aguds-hero-enabled .ag-search-field input {
    font-size: 13px !important;
    font-weight: 550 !important;
    line-height: 1.25 !important;
}

/* Keep placeholder proportional to typed text. */
html body #ag-new-hero.aguds-hero-enabled .ag-search-field input::placeholder {
    font-size: 13px !important;
}

/* Results section kicker. */
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-results-heading {
    font-size: 10.5px !important;
    line-height: 1.2 !important;
}

/* Give the larger avatar/logo and text a little more breathing room. */
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-result-row,
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-space-payload .listing-item .content-inner {
    min-height: 64px !important;
    gap: 12px !important;
    padding: 9px 10px !important;
}

/* Artist profile photos and Art Spaces logos: one step larger. */
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-result-avatar,
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-space-payload .listing-item .lt-logo {
    width: 48px !important;
    height: 48px !important;
    flex: 0 0 48px !important;
}

/* Result names: one step larger without making the list bulky. */
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-result-copy strong,
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-space-payload .listing-item .title {
    font-size: 14px !important;
    line-height: 1.22 !important;
}

/* Artist meta / Art Spaces address. */
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-result-copy small,
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-space-payload .listing-item .address {
    font-size: 11px !important;
    line-height: 1.3 !important;
}

/* Keep arrow visually balanced with larger identity rows. */
html body #ag-new-hero.aguds-hero-enabled .aguds-hero-result-arrow {
    font-size: 25px !important;
}
