/* Amish Built Cabins – Live Search v2
   NO trigger button styles here.
   Add class "abc-open-search" to ANY element you build in Elementor to open the panel. */

/* ── Overlay ── */
#abc-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99998;
    background: rgba(0,0,0,0.35);
}
#abc-overlay.active { display: block; }

/* ── Search panel ── */
#abc-search-panel {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 3px solid #e8692a;
    box-shadow: 0 8px 40px rgba(0,0,0,0.18);
    z-index: 99999;
    transform: translateY(-110%);
    transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
    max-height: 90vh;
    overflow-y: auto;
}
#abc-search-panel.open {
    transform: translateY(0);
}

/* ── Search bar row ── */
.abc-panel-inner {
    padding: 16px 20px 12px;
    background: #1a2332;
}

.abc-bar {
    display: flex;
    align-items: center;
    background: #fff;
    border: 2px solid #e8692a;
    border-radius: 40px;
    padding: 10px 16px;
    gap: 10px;
    max-width: 680px;
    margin: 0 auto;
}

.abc-input {
    border: none !important;
    outline: none !important;
    background: transparent !important;
    font-size: 16px !important;
    flex: 1;
    color: #1a2332 !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
    min-width: 0;
    font-family: inherit;
}
.abc-input::placeholder { color: #aaa; }

.abc-clear {
    background: none;
    border: none;
    cursor: pointer;
    color: #aaa;
    padding: 0;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    transition: color 0.15s;
    line-height: 1;
}
.abc-clear:hover { color: #444; }

.abc-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid #fde8d9;
    border-top-color: #e8692a;
    border-radius: 50%;
    animation: abcSpin 0.6s linear infinite;
    display: none;
    flex-shrink: 0;
}
@keyframes abcSpin { to { transform: rotate(360deg); } }

/* ── Suggestions ── */
#abc-suggestions {
    max-width: 680px;
    margin: 0 auto;
    padding: 0 20px;
}

.abc-results-label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: #e8692a;
    text-transform: uppercase;
    padding: 12px 0 4px;
}

.abc-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 0;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    text-decoration: none;
    color: inherit;
    transition: background 0.12s;
}
.abc-item:last-of-type { border-bottom: none; }
.abc-item:hover,
.abc-item.active { background: #fff8f5; padding-left: 8px; padding-right: 8px; margin: 0 -8px; border-radius: 8px; }

.abc-thumb {
    width: 56px;
    height: 56px;
    border-radius: 10px;
    border: 1px solid #eee;
    flex-shrink: 0;
    background: #f0e8e0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}
.abc-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.abc-info { flex: 1; min-width: 0; }

.abc-name {
    font-size: 14px;
    font-weight: 600;
    color: #1a2332;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}
.abc-name mark {
    background: none;
    color: #e8692a;
    font-weight: 700;
}

.abc-meta {
    font-size: 12px;
    color: #888;
    margin-top: 3px;
}

.abc-badge {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    background: #fff3ec;
    color: #c85820;
    border-radius: 20px;
    padding: 2px 7px;
    margin-left: 6px;
    vertical-align: middle;
}

.abc-price-wrap { text-align: right; flex-shrink: 0; }
.abc-price {
    font-size: 14px;
    font-weight: 700;
    color: #e8692a;
    display: block;
}
.abc-regular {
    font-size: 11px;
    color: #bbb;
    text-decoration: line-through;
    display: block;
}

.abc-no-results {
    padding: 24px 0;
    text-align: center;
    color: #aaa;
    font-size: 14px;
}

.abc-view-all {
    display: block;
    text-align: center;
    padding: 14px;
    font-size: 13px;
    font-weight: 600;
    color: #e8692a;
    background: #fff8f5;
    border-top: 1px solid #ffe5d4;
    text-decoration: none;
    transition: background 0.12s;
    margin: 8px -20px 0;
}
.abc-view-all:hover { background: #ffe5d4; color: #c85820; }

/* ── Keyboard hint ── */
.abc-kbd-hint {
    display: flex;
    gap: 16px;
    justify-content: center;
    padding: 8px 20px;
    font-size: 11px;
    color: #ccc;
    background: #1a2332;
}
.abc-kbd-hint kbd {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 4px;
    padding: 1px 5px;
    font-size: 10px;
    color: #ccc;
    font-family: monospace;
}

/* ── Mobile ── */
@media (max-width: 600px) {
    .abc-panel-inner { padding: 12px; }
    #abc-suggestions { padding: 0 12px; }
    .abc-view-all { margin: 8px -12px 0; }
}
