/* ==========================================================================
   📌 Search & Matching Overlays (Lobby & Plot Board)
   ========================================================================== */

/* --- Lobby Search / Matching Status --- */
.chat-search-overlay {
    position: absolute;
    top: 60px; /* below the header */
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--surface); /* Solid matching theme background to cover underlying inputs and blur */
    border-bottom-left-radius: 16px;
    border-bottom-right-radius: 16px;
    overflow: hidden;
    z-index: 200;
    transition: opacity 0.3s var(--ease), visibility 0.3s var(--ease);
}

.chat-search-overlay.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.chat-search-radar {
    position: relative;
    width: 200px;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
}

.radar-logo {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--accent-color);
    box-shadow: 0 0 30px var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 32px;
    font-weight: 700;
    z-index: 4;
    animation: pulse-logo 1.8s infinite cubic-bezier(0.215, 0.610, 0.355, 1);
}

.radar-logo .ui-icon {
    margin: 0 !important;
    display: block !important;
}

.radar-circle {
    position: absolute;
    border: 1px solid var(--accent-color);
    border-radius: 50%;
    opacity: 0;
    animation: radar-pulse 3.6s infinite linear;
}

.circle-1 {
    width: 100px;
    height: 100px;
    animation-delay: 0s;
}

.circle-2 {
    width: 150px;
    height: 150px;
    animation-delay: 1s;
}

.circle-3 {
    width: 200px;
    height: 200px;
    animation-delay: 2s;
}

.chat-search-status-text {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 8px;
    text-align: center;
    letter-spacing: 0.01em;
}

.chat-search-tip {
    font-size: 0.85rem;
    color: var(--text-2);
    max-width: 280px;
    text-align: center;
    line-height: 1.4;
    transition: opacity 0.3s ease;
}

/* --- Plot Board Search / Pinned Plot Waiting Status --- */
.plot-waiting-search-panel {
    width: min(92%, 560px);
    margin: 14px auto 8px;
    padding: 20px 18px;
    border: 1px solid rgba(167, 139, 250, 0.22);
    border-radius: var(--radius-md);
    background: var(--surface-2);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    box-shadow: 0 8px 26px rgba(0, 0, 0, 0.14);
}

.plot-waiting-radar {
    position: relative;
    width: 128px;
    height: 128px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
}

.plot-waiting-radar-circle {
    position: absolute;
    border: 1px solid rgba(167, 139, 250, 0.7);
    border-radius: 50%;
    opacity: 0;
    animation: plotWaitingRadar 3.6s infinite linear;
}

.plot-waiting-radar-circle-1 {
    width: 58px;
    height: 58px;
    animation-delay: 0s;
}

.plot-waiting-radar-circle-2 {
    width: 88px;
    height: 88px;
    animation-delay: 1s;
}

.plot-waiting-radar-circle-3 {
    width: 118px;
    height: 118px;
    animation-delay: 2s;
}

.plot-waiting-logo {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: rgba(124, 58, 237, 0.16);
    border: 1px solid rgba(167, 139, 250, 0.38);
    color: #c4b5fd;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    box-shadow: 0 0 14px rgba(124, 58, 237, 0.18);
    animation: plotWaitingLogo 2.2s ease-in-out infinite;
}

.plot-waiting-logo .ui-icon {
    width: 28px;
    height: 28px;
    margin: 0 !important;
    display: block !important;
}

.plot-waiting-status {
    font-size: var(--fs-lg);
    font-weight: 800;
    color: var(--text);
    margin-bottom: 6px;
}

.plot-waiting-note {
    max-width: 360px;
    color: var(--text-2);
    font-size: var(--fs-sm);
    line-height: 1.45;
}

/* ==========================================================================
   📌 Keyframe Animations
   ========================================================================== */

@keyframes pulse-logo {
    0% {
        transform: scale(1);
    }
    14% {
        transform: scale(1.16);
    }
    28% {
        transform: scale(1.05);
    }
    42% {
        transform: scale(1.22);
    }
    70%, 100% {
        transform: scale(1);
    }
}

@keyframes radar-pulse {
    0% {
        transform: scale(0.6);
        opacity: 0.8;
    }
    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

@keyframes plotWaitingRadar {
    0% {
        transform: scale(0.65);
        opacity: 0.78;
    }
    100% {
        transform: scale(1.55);
        opacity: 0;
    }
}

@keyframes plotWaitingLogo {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.08);
    }
}
