/* 搜索弹窗样式 */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-y: auto;
}

.glass-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* 标签导航 */
.glass-tabs {
    display: flex;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    background: rgba(255, 255, 255, 0.8);
    position: relative;
}

.glass-tabs .tab-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-size: 14px;
    color: #666;
    border-radius: 8px;
    transition: all 0.3s;
    margin-right: 8px;
}

.glass-tabs .tab-btn:hover {
    background: rgba(0, 0, 0, 0.05);
    color: #333;
}

.glass-tabs .tab-btn.active {
    background: rgba(0, 0, 0, 0.1);
    color: #000;
    font-weight: 600;
}

.glass-tabs .tab-icon {
    width: 18px;
    height: 18px;
}

.glass-close {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    color: #666;
}

.glass-close:hover {
    background: rgba(0, 0, 0, 0.1);
    color: #000;
}

.glass-close svg {
    width: 20px;
    height: 20px;
}

/* 内容区域 */
.glass-content {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

/* 节点导航 */
.sub-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.sub-pill {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s;
    background: rgba(0, 0, 0, 0.05);
    color: #666;
    border: 1px solid transparent;
}

.sub-pill:hover {
    background: rgba(0, 0, 0, 0.1);
    color: #333;
}

.sub-pill.active {
    background: #2ea44f;
    color: #fff;
    border-color: #2ea44f;
}

/* 搜索输入组 */
.glass-input-group {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.glass-input-group input {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    font-size: 14px;
    outline: none;
    transition: all 0.3s;
}

.glass-input-group input:focus {
    border-color: #2ea44f;
    box-shadow: 0 0 0 3px rgba(46, 164, 79, 0.1);
}

.glass-search-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: #2ea44f;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.glass-search-btn:hover {
    background: #2c974b;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(46, 164, 79, 0.3);
}

.glass-search-btn:active {
    transform: translateY(0);
}

.glass-search-btn svg {
    width: 18px;
    height: 18px;
}

/* 搜索历史 */
.search-history {
    margin-top: 20px;
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-size: 13px;
    color: #666;
}

.clear-history-btn {
    padding: 4px 12px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    background: transparent;
    border-radius: 4px;
    font-size: 12px;
    color: #666;
    cursor: pointer;
    transition: all 0.3s;
}

.clear-history-btn:hover {
    background: rgba(0, 0, 0, 0.05);
    color: #333;
}

.history-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.history-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
    color: #333;
    border: 1px solid transparent;
}

.history-item:hover {
    background: rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.history-keyword {
    font-size: 14px;
    color: #333;
    font-weight: 500;
}

.history-scope-tag {
    font-size: 12px;
    color: #666;
    background: rgba(0, 0, 0, 0.08);
    padding: 2px 8px;
    border-radius: 12px;
    font-weight: normal;
}

/* 移动端适配 */
@media screen and (max-width: 768px) {
    .search-overlay {
        padding: 0;
        align-items: flex-start;
    }

    .glass-card {
        max-width: 100%;
        max-height: 100vh;
        border-radius: 0;
    }

    .glass-tabs {
        padding: 12px;
    }

    .glass-tabs .tab-btn {
        padding: 6px 12px;
        font-size: 13px;
    }

    .glass-content {
        padding: 16px;
    }

    .sub-nav {
        gap: 6px;
    }

    .sub-pill {
        padding: 5px 10px;
        font-size: 12px;
    }

    .glass-input-group {
        flex-direction: column;
    }

    .glass-search-btn {
        width: 100%;
        justify-content: center;
    }
}

